Gnuplot/C2/Example-scripts-and-demo-folder/English
Visual Cue | Narration |
Slide Number 1
Example Scripts and demo folder |
Welcome to the tutorial on Example Scripts and Demo Folder |
Slide Number 2
Learning Objectives |
In this tutorial, we will
|
Slide Number 3
System and Software Requirement |
To record this tutorial, I am using,
It may work with other versions also. |
Slide Number 4
Pre-requisites |
To follow this tutorial, learners must be familiar with,
|
Slide Number 5
Download link |
Download link for gnuplot example files is gnuplot dot info
Example Script files are downloaded in the tar ball They are extracted to the demo folder |
Press ctrl alt t keys together. | First, open a terminal, by pressing control, alt, t keys together on keyboard. |
cd ~/Downloads/gnuplot-5.2.5/demo | A terminal opens.
Change directory to the demo directory of the extracted tar ball. Enter command, as seen on the screen to change the directory. |
I have downloaded and extracted gnuplot files here. | |
The example files are in the demo folder of the extracted tar ball.
Learners must change directory to the demo folder in their computer. | |
Hover mouse or highlight path in terminal | Now working directory change to demo folder. |
There is a chance your computer does not have the demo files. | |
If so, pause the video and download them from gnuplot website.
Extract the demo directory from the downloaded tar ball file. | |
ls | Enter command ls to list the files. |
Notice, several files with dot dem extension. | |
Scroll up | They are simple text scripts, which are used to generate the plots |
Ctrl alt k | I will also clear the screen for clarity in video |
Demonstration files are short scripts that plot graphs
Let's look at their structure now. | |
Type gedit simple.dem and press enter | Type gedit space simple dot dem and press enter |
The script file opens in gedit.
Windows users may open the file in notepad to study the structure of the script | |
Hover mouse near required files in header. | Details about this plot are mentioned in the header.
The required data files are also mentioned. This script plots three functions together. |
Scroll down | Scroll down to view the file.
Now we have seen a script structure. |
Close gedit | Feel free to go through this file and explore more.
Close gedit by clicking on the x sign |
Next, let's run the script in gnuplot and generate the plot. | |
>gnuplot
Press enter |
In terminal prompt, type gnuplot and press enter to open gnuplot. |
Hover mouse near gnuplot prompt | The plot changes to gnuplot prompt.
To execute a command in terminal, press enter. I will not mention it separately. |
ctrl shift K | I will clear the screen and bring prompt to top of the terminal for clarity. |
>load space 'simple.dem' | To load a script, enter command as seen.
|
Hover mouse next to Sin(x), atan(x) and cos(atan(x)) | Three functions, sin x, atan x and cos atan x are plotted. |
Scroll further in axis limits | Using arrow keys, scroll, left, right, up and down in the plot.
|
Hover mouse next to “press enter to continue” and press enter | Simple dot dem can plot many graphs.
I encourage you to go through the script file again, at this stage. To see every new plot, do the following. Go to the terminal by clicking on it.
|
Show the change in graphics window | Then next script and it's function gets plotted. |
Press enter | Press enter again, as shown in prompt to plot the functions from next script. |
You may pause the video and scroll over more demonstration files. | |
Close graphical window | I will now close the graphical window |
Press ctrl c | We can also enter the commands sequentially in the terminal to generate plot.
I encourage you to try other demo files in this folder. Press ctrl -c to come back to gnuplot prompt. |
Press q | Enter command, q to exit gnuplot |
Many example scripts are available online for gnuplot
| |
I will show how to access the examples files online in the next step. | |
Open web browser.
Go to, gnuplot.sourceforge.net/demo |
I will open firefox web browser.
Go to, web address as seen in the video
|
Scroll down and show | Notice the several demos and scripts for users to learn from. |
Hover mouse over routine | 2D and 3D graphs, histograms and curve fitting are few capabilities of software. |
Click on Simple functions | Click on the Simple functions link |
Hover mouse over graph, pan right | Left side shows graphical plots.
|
Scroll down pan left | Scroll down the page and notice the various styles in plots on the left side. |
Hover mouse over graph | Notice the variations in symbols, color, legends, line style and filling area. |
Learners may use this page to learn the various commands and options | |
Slide Number 6
Summary |
Now let's summarize.
In this tutorial, we
|
Slide Number 7
Assignment |
For assignment activity, please do the following
|
Slide Number 8
Assignment
|
This is what this help page looks like. |
Slide Number 9
Spoken Tutorial Project |
This video summarises the Spoken Tutorial Project
Please download and watch it. |
Slide Number 10
Spoken Tutorial workshops |
The Spoken Tutorial Project Team
For more details, please write to us. |
Slide Number 11
Forum for specific questions: |
Post your timed queries in the forum. |
Slide Number 12
Acknowledgement> |
Spoken Tutorial Project is funded by NMEICT, MHRD, Government of India. |
This is Rani from IIT, Bombay. Thank you for joining. |