|
From: Alberich de m. <alb...@gm...> - 2012-12-09 12:23:51
|
Hello list! I'm writing my PhD tesis, and I need to compare some values in an special way. I have 3 columns with numbers, the 3rd columns has a reference measeure value for the current way the algorithm works. I split it into 2 steps (col 1 and 2 respectively), so the time for this columns should be added and compared with the 3rd col. And I want to stack the first 2 (so I can still see the time for each step) and this stacked column cluster it the third column. I couldn't find anthing about this. Is it possible to do this with gnuplot? thanks! |
|
From: Leo B. <l_b...@us...> - 2012-12-09 14:50:51
|
Alberich de megres <alb...@gm...> writes: > Hello list! > > I'm writing my PhD tesis, and I need to compare some values in an special > way. > > I have 3 columns with numbers, the 3rd columns has a reference measeure > value for the current way the algorithm works. I split it into 2 steps (col > 1 and 2 respectively), so the time for this columns should be added and > compared with the 3rd col. Could you provide a simple example? It seems you have something like # t1 t2 t3 1 2 3 4 5 7 etc. Do you intend to add columns 1+2 row-wise? If so: plot 'data' using ($1+$2) title 'cols 1+2', '' using 3 title 'col 3' > And I want to stack the first 2 (so I can still > see the time for each step) and this stacked column cluster it the third > column. I don't understand what you want to do here, since the stacked cols 1 and 2 will have twice the number of entries as column 3. An example could clarify. > > I couldn't find anthing about this. Is it possible to do this with gnuplot? Probably with some combination of gnuplot and awk or perl. -- Leo Butler <l_b...@us...> SDF Public Access UNIX System - http://sdf.lonestar.org |
|
From: Alberich de m. <alb...@gm...> - 2012-12-09 15:03:50
|
Yes, sorry. I can provide a very simple example. The original algorithm takes let's say 10s to complete. As I devided it into 2 steps, step 1 takes 4s and step 2 takes 3s So the new algorithm will be the result of exacuting step 1 and then step 2, and it overall time will now be time to complete step 1 + time to complete step 2, in the example, 4+3=7. Now I want to compare it with the old one, which takes 10s. My idea was stack step1 and step2 into one bar (keeping track of each part time), and the cluster it the old value. Or in other works, cluster two bars but one of them will be the result of stacking step 1 and 2 into one bar. my input file could look like that: 4 3 10 5 6 8 8 19 20 .. Thanks! On Sun, Dec 9, 2012 at 3:35 PM, Leo Butler <l_b...@us...>wrote: > Alberich de megres <alb...@gm...> writes: > > > Hello list! > > > > I'm writing my PhD tesis, and I need to compare some values in an special > > way. > > > > I have 3 columns with numbers, the 3rd columns has a reference measeure > > value for the current way the algorithm works. I split it into 2 steps > (col > > 1 and 2 respectively), so the time for this columns should be added and > > compared with the 3rd col. > > Could you provide a simple example? It seems you have something like > > # t1 t2 t3 > 1 2 3 > 4 5 7 > etc. > > Do you intend to add columns 1+2 row-wise? If so: > > plot 'data' using ($1+$2) title 'cols 1+2', '' using 3 title 'col 3' > > > And I want to stack the first 2 (so I can still > > see the time for each step) and this stacked column cluster it the third > > column. > > I don't understand what you want to do here, since the stacked cols 1 > and 2 will have twice the number of entries as column 3. An example > could clarify. > > > > > I couldn't find anthing about this. Is it possible to do this with > gnuplot? > > Probably with some combination of gnuplot and awk or perl. > > -- > Leo Butler <l_b...@us...> > SDF Public Access UNIX System - http://sdf.lonestar.org > |
|
From: Leo B. <l_b...@us...> - 2012-12-09 20:40:07
|
Alberich de megres <alb...@gm...> writes: > [1:text/plain Hide] > > Yes, sorry. > > I can provide a very simple example. The original algorithm takes let's > say 10s to complete. As I devided it into 2 steps, step 1 takes 4s and step > 2 takes 3s > > So the new algorithm will be the result of exacuting step 1 and then step > 2, and it overall time will now be time to complete step 1 + time to > complete step 2, in the example, 4+3=7. Now I want to compare it with the > old one, which takes 10s. > > My idea was stack step1 and step2 into one bar (keeping track of each part > time), and the cluster it the old value. Or in other works, cluster two > bars but one of them will be the result of stacking step 1 and 2 into one > bar. > > my input file could look like that: > > 4 3 10 > 5 6 8 > 8 19 20 > .. > > > Thanks! I think that my suggestion will do what you want: >> plot 'data' using ($1+$2) title 'cols 1+2', '' using 3 title 'col 3' Leo > > > > > > > > > > On Sun, Dec 9, 2012 at 3:35 PM, Leo Butler > <l_b...@us...>wrote: > >> Alberich de megres <alb...@gm...> writes: >> >> > Hello list! >> > >> > I'm writing my PhD tesis, and I need to compare some values in an special >> > way. >> > >> > I have 3 columns with numbers, the 3rd columns has a reference measeure >> > value for the current way the algorithm works. I split it into 2 steps >> (col >> > 1 and 2 respectively), so the time for this columns should be added and >> > compared with the 3rd col. >> >> Could you provide a simple example? It seems you have something like >> >> # t1 t2 t3 >> 1 2 3 >> 4 5 7 >> etc. >> >> Do you intend to add columns 1+2 row-wise? If so: >> >> plot 'data' using ($1+$2) title 'cols 1+2', '' using 3 title 'col 3' >> >> > And I want to stack the first 2 (so I can still >> > see the time for each step) and this stacked column cluster it the third >> > column. >> >> I don't understand what you want to do here, since the stacked cols 1 >> and 2 will have twice the number of entries as column 3. An example >> could clarify. >> >> > >> > I couldn't find anthing about this. Is it possible to do this with >> gnuplot? >> >> Probably with some combination of gnuplot and awk or perl. >> >> -- >> Leo Butler <l_b...@us...> >> SDF Public Access UNIX System - http://sdf.lonestar.org >> > > [2:text/html Show] > -- Leo Butler <l_b...@us...> SDF Public Access UNIX System - http://sdf.lonestar.org |