Correct method to normalize two data sets

914 Views Asked by At

I have to normalize two data sets w.r.t y-axis values while x -axis values are common in both. I have used in gnulpot three different methods, can any one tell which one is correct? since on web there are multiple ways given. Data set #1 (data3.dat)

0.3 2391
0.4 2203
0.5 2819
0.6 2795
0.7 2664    
0.8 3139    
0.9 3652

Data set #2 (data4.dat)

0.3 0.00107
0.4 0.00113
0.5 0.00196
0.6 0.00169 
0.7 0.00255 
0.8 0.00292
0.9 0.00363

Method 1: divide y axis values with largest y value in respective data set and plot

stats "data3.dat" using 1:2 name "A"
stats "data4.dat" using 1:2 name "B"

plot "data3.dat" using 1:($2/A_max_y) w lp,"data4.dat" using 1:($2/B_max_y) w lp

The output looks like this

enter image description here

Method2: Divide second data set with largest y value of both data set and plot

stats "data3.dat" using 1:2 name "A"
stats "data4.dat" using 1:2 name "B"

plot "data3.dat" using 1:2 w lp,"data4.dat" using 1:($2/A_max_y*B_max_y) w lp

The output looks like this

enter image description here