Gnuplot Script for Routing Over Head, Packet Delivery Ratio and End-to-End Delay

Here are my gnuplot script to make a graph using gnuplot. In this case I compared 3 AODV routing protocols .

ROH.gplot script

#To displat any the data, run gnuplot, and type
#   load "ROH.gplot"
set ylabel "Routing Over Head (Bytes)"
set xlabel "Pause Time (s)"
set xrange [0:500]
set yrange [0:10000]
set key right bottom box
plot "/home/abdusy/Documents/aodv-simulation/data-compare/ui-roh.txt" using 1:2 title "AODV-UI" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/ali-roh.txt" using 1:2 title "AODV+" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/uu-roh.txt" using 1:2 title "AODV-UU" with linespoint

PDR.gplot script

#To display any the data, run gnuplot, and type
#   load "PDR.gplot"
set yrange [50:105]
set ylabel "Packet Delivery Ratio (%)"
set xlabel "Pause Time (s)"
set xrange [0:500]
set key right bottom box
plot "/home/abdusy/Documents/aodv-simulation/data-compare/ui-pdr.txt" using 1:2 title "AODV-UI" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/ali-pdr.txt" using 1:2 title "AODV+" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/uu-pdr.txt" using 1:2 title "AODV-UU" with linespoint

E2E.gplot script

#To display any the data, run gnuplot, and type
#   load "E2E.gplot"
set yrange [0:0.005]
set ylabel "Av.End-to-End Delay (s)"
set xlabel "Pause Time (s)"
set xrange [0:500]
set key right bottom box
plot "/home/abdusy/Documents/aodv-simulation/data-compare/ui-e2e.txt" using 1:2 title "AODV-UI" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/ali-e2e.txt" using 1:2 title "AODV+" with linespoint
replot "/home/abdusy/Documents/aodv-simulation/data-compare/uu-e2e.txt" using 1:2 title "AODV-UU" with linespoint

To use this script, you have to go to your directory where you put your data. As you can see, I put all my data in “/home/abdusy/Documents/aodv-simulation/data-compare/”. Then type ‘gnuplot’, it will show :

gnuplot >
gnuplot > load "E2E.gplot"

end-to-end delay

Advertisements

Tags: , , , , , , ,

One Response to “Gnuplot Script for Routing Over Head, Packet Delivery Ratio and End-to-End Delay”

  1. umair Says:

    Hi ,I need awk script for calculating routing overhead in ns2 ,I am comparing protocols like aodv and olsr so I need them I searched a lot in ns mailing list but can’t find the correct one .Can you please upload it here on your blog?

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: