Created scale vector function