<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://script.spoken-tutorial.org/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=Grace%2FC3%2FData-Fitting%2FEnglish-timed</id>
		<title>Grace/C3/Data-Fitting/English-timed - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://script.spoken-tutorial.org/index.php?action=history&amp;feed=atom&amp;title=Grace%2FC3%2FData-Fitting%2FEnglish-timed"/>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=Grace/C3/Data-Fitting/English-timed&amp;action=history"/>
		<updated>2026-04-29T23:09:38Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.17</generator>

	<entry>
		<id>https://script.spoken-tutorial.org/index.php?title=Grace/C3/Data-Fitting/English-timed&amp;diff=56012&amp;oldid=prev</id>
		<title>PoojaMoolya: Created page with &quot;{|border=1 ||'''Time''' ||'''Narration'''  |- || 00:01 || Welcome to the tutorial on '''Data fitting''' in '''Grace'''.  |- || 00:06 || In this tutorial, we will  Fit a given...&quot;</title>
		<link rel="alternate" type="text/html" href="https://script.spoken-tutorial.org/index.php?title=Grace/C3/Data-Fitting/English-timed&amp;diff=56012&amp;oldid=prev"/>
				<updated>2022-08-30T07:37:09Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;{|border=1 ||&amp;#039;&amp;#039;&amp;#039;Time&amp;#039;&amp;#039;&amp;#039; ||&amp;#039;&amp;#039;&amp;#039;Narration&amp;#039;&amp;#039;&amp;#039;  |- || 00:01 || Welcome to the tutorial on &amp;#039;&amp;#039;&amp;#039;Data fitting&amp;#039;&amp;#039;&amp;#039; in &amp;#039;&amp;#039;&amp;#039;Grace&amp;#039;&amp;#039;&amp;#039;.  |- || 00:06 || In this tutorial, we will  Fit a given...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{|border=1&lt;br /&gt;
||'''Time'''&lt;br /&gt;
||'''Narration'''&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:01&lt;br /&gt;
|| Welcome to the tutorial on '''Data fitting''' in '''Grace'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:06&lt;br /&gt;
|| In this tutorial, we will&lt;br /&gt;
&lt;br /&gt;
Fit a given set of data points to a linear equation&lt;br /&gt;
 &lt;br /&gt;
|-&lt;br /&gt;
|| 00:14&lt;br /&gt;
|| Add two datasets to a graph panel&lt;br /&gt;
 &lt;br /&gt;
|-&lt;br /&gt;
|| 00:18&lt;br /&gt;
|| Add legends and format the legend properties&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:24&lt;br /&gt;
|| To record this tutorial, I am using&lt;br /&gt;
&lt;br /&gt;
'''Ubuntu Linux''' 16.04 OS&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:33&lt;br /&gt;
|| '''Grace''' 5.1.25 and  '''Gedit''' 3.18.3&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:42&lt;br /&gt;
|| To follow this tutorial, &lt;br /&gt;
&lt;br /&gt;
Learner must be familiar with the '''Grace''' interface.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:48&lt;br /&gt;
||  For pre-requisite tutorials, please visit this website.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 00:54&lt;br /&gt;
||  Data fitting is a process to find a mathematical relation between two variables.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:01&lt;br /&gt;
|| An equation is used to describe the XY dataset pair.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
||01:06&lt;br /&gt;
|| Using an iterative process, the coefficients are optimized.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:11&lt;br /&gt;
|| The process returns the best possible coefficients for the equation.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:17&lt;br /&gt;
|| Go to '''Desktop'''.  Notice the file, '''line-fit.txt'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:24&lt;br /&gt;
|| This file is provided to you in the '''Code Files''' link. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:29&lt;br /&gt;
|| I have downloaded, extracted and saved the file to the '''Desktop''' directory.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:36&lt;br /&gt;
|| Next, open the '''Grace''' program and load this file to plot an '''XY''' graph.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:43&lt;br /&gt;
|| Choose '''XY''' data set, and '''autoscale''' data. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:48&lt;br /&gt;
|| Next I will format the plot.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:52&lt;br /&gt;
|| I have changed the symbols, line style, tick marks and axis labels.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 01:59&lt;br /&gt;
|| The data points do not lie on a straight line. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:04&lt;br /&gt;
|| The data points look scattered around a straight line.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:08&lt;br /&gt;
|| We will fit this data to a straight line.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:12&lt;br /&gt;
|| For a straight line, this is process is called '''linear regression'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:18&lt;br /&gt;
|| A straight line is described by an equation in two variables,&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:24&lt;br /&gt;
|| The equation has the form, y equals mx+c.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:29&lt;br /&gt;
|| Here, m is the slope of the line and c is the intercept. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:36&lt;br /&gt;
|| Go to '''Data''' and select '''Transformations'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:42&lt;br /&gt;
|| Notice the available options.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:46&lt;br /&gt;
|| Choose '''Regression''' from the list.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:48&lt;br /&gt;
||A '''Regression''' dialog box opens.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:52&lt;br /&gt;
|| Choose the data set of interest from '''Apply to set'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 02:58&lt;br /&gt;
|| Currently only a single set is loaded and it is shown as '''S0'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:05&lt;br /&gt;
|| The next number is the number of points that are present in the dataset.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:12&lt;br /&gt;
|| If many datasets are loaded more sets will be seen, in the '''Apply to set''' box. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:19&lt;br /&gt;
|| Choose '''linear''' for '''Type of fit'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:23&lt;br /&gt;
|| In the '''Load''' drop-down, choose '''Fitted values'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:29&lt;br /&gt;
|| For '''restrictions''' choose '''None'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:33&lt;br /&gt;
|| If only part of the data set needs to be fitted, enter the required range.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:39&lt;br /&gt;
|| We can also specify the '''start load at''' and '''stop load at''' values in the form. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:47&lt;br /&gt;
|| I will leave it as is and will not make changes here.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:52&lt;br /&gt;
|| Click on '''Accept''' to run the data fitting.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:56&lt;br /&gt;
|| The data fitting algorithm runs.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 03:59&lt;br /&gt;
|| A '''Grace console''' window appears with mathematical details.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:04&lt;br /&gt;
|| We can see the equation used for the fitting.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:08&lt;br /&gt;
|| The output values of residual, slope, intercept and other parameters are seen.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:17&lt;br /&gt;
|| The fitted line appears on the screen.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:21&lt;br /&gt;
|| The fitted values are loaded in a different set, '''S1'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:26&lt;br /&gt;
|| Click on '''File''', '''Save''' to save the parameters.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:31&lt;br /&gt;
|| The '''Grace: Save logs''' window opens.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
||04:35&lt;br /&gt;
|| In '''Save to file '''text box, type the filename as '''line-regression.txt'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:43&lt;br /&gt;
|| Click on '''Apply''' and then click on '''Close''' to close the dialog box.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:49&lt;br /&gt;
|| Close the '''Grace Console''' by '''File''', '''Close''' or press the'''Esc''' key.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 04:56&lt;br /&gt;
|| Click on '''Close''' in the '''Regression''' window.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:00&lt;br /&gt;
|| Double click on the line in the graph.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:03&lt;br /&gt;
|| '''Grace Set appearance''' window opens.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:07&lt;br /&gt;
|| In the '''select set''' form, select '''S1''' data set.&lt;br /&gt;
&lt;br /&gt;
This is the fitted data.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:15&lt;br /&gt;
|| Right click to open the context menu. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:19&lt;br /&gt;
|| Select '''Edit''', and in '''In spreadsheet''' option. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:24&lt;br /&gt;
|| The '''Grace: Spreadsheet dataset editor''' appears.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:29&lt;br /&gt;
|| Notice the x and corresponding fitted y values of the fitted data.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:36&lt;br /&gt;
|| These values are different from the input data.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:40&lt;br /&gt;
|| This line fits the input data best, with a linear equation.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:46&lt;br /&gt;
|| Close the '''Spreadsheet dataset Editor'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:50&lt;br /&gt;
|| The original data set and the fitted values are the 2 datasets in the graph.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 05:58&lt;br /&gt;
|| Datasets are labeled as ['''S0'''] for first set and ['''S1'''] for the second set.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:05&lt;br /&gt;
|| We can add more datasets to this graph panel.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:10&lt;br /&gt;
|| For this load the data using the '''Data, import, ASCII''' option from the menu.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:18&lt;br /&gt;
|| Next, we will add legends to the plot.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:22&lt;br /&gt;
|| Open the '''Set Appearance''' window and choose the dataset '''S0'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:29&lt;br /&gt;
|| Under '''Legend''', in the '''String''' field, type '''Data''' as the legend label. &lt;br /&gt;
Click on '''Apply'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:38&lt;br /&gt;
|| Next choose '''S1''' dataset from the '''Select set''' data form.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:45&lt;br /&gt;
|| Here, I will type '''Fitted data''' for the legend and click on '''Apply'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:53&lt;br /&gt;
|| Close the '''Set Appearance''' window.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 06:57&lt;br /&gt;
|| For some users, the '''legend''' position may be outside the graph border.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:03&lt;br /&gt;
|| To reposition the '''legends''', place the cursor in the '''legend''' box.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:09&lt;br /&gt;
|| Then press '''Control''' and '''L''' keys together.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:13&lt;br /&gt;
|| The cursor changes to a pointer.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:17&lt;br /&gt;
|| Left click and drag the '''legend''' box to the desired position.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:24&lt;br /&gt;
|| Then, press '''Enter'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:27&lt;br /&gt;
|| Press the '''Escape''' key to exit the movement mode.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:32&lt;br /&gt;
|| Next, open the '''Graph appearance''' window.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:36&lt;br /&gt;
|| In the window, click on the '''Legends''' tab, to format the '''legend''' fonts.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:43&lt;br /&gt;
|| Under the '''text properties''', move the character size slider to 70.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:49&lt;br /&gt;
|| The legends look very large compared to the graph.&lt;br /&gt;
|-&lt;br /&gt;
|| 07:53&lt;br /&gt;
|| I will retain the font type as '''Times-Roman'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 07:58&lt;br /&gt;
|| Click on '''Apply''' to apply the changes.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:02&lt;br /&gt;
|| Click on the '''legend box''' tab.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:06&lt;br /&gt;
|| We can also specify the position of the '''legend''' in the location section.&lt;br /&gt;
&lt;br /&gt;
I will leave it as is.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:10&lt;br /&gt;
|| In the '''Frame line''' section, for '''Pattern''', I will choose '''None'''. &lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:22&lt;br /&gt;
|| Click on '''Apply'''.&lt;br /&gt;
&lt;br /&gt;
This will remove the legend frame box.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:28&lt;br /&gt;
|| Then '''Close''' the dialog box.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:31&lt;br /&gt;
|| Now save the project in the '''Desktop''' directory.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:36&lt;br /&gt;
|| I will use the file name '''regression dot agr'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:41&lt;br /&gt;
|| Press '''Control Q''' or Click on '''File, Exit''' to exit '''Grace'''.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:49&lt;br /&gt;
|| Let’s summarize.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:51&lt;br /&gt;
|| In this tutorial we,&lt;br /&gt;
&lt;br /&gt;
Performed data fitting for a straight line.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 08:57&lt;br /&gt;
||Added two datasets in the graph panel.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:01&lt;br /&gt;
||Added legends to the plot and  Formatted the legend properties.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:08&lt;br /&gt;
|| For assignment activity, please do the following.&lt;br /&gt;
 &lt;br /&gt;
|-&lt;br /&gt;
|| 09:13&lt;br /&gt;
|| Two assignment files are provided in the Code files link.&lt;br /&gt;
 &lt;br /&gt;
|-&lt;br /&gt;
|| 09:18&lt;br /&gt;
|| Plot them in the same graph panel.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:22&lt;br /&gt;
||  Perform quadratic regression on the '''parabola1.txt''' file.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:28&lt;br /&gt;
||  Load the fitted data in the graph.&lt;br /&gt;
 &lt;br /&gt;
|-&lt;br /&gt;
|| 09:32&lt;br /&gt;
|| Add legend strings and reposition them inside the graph panel.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:38&lt;br /&gt;
||  Format the appearance of the three datasets to distinguish them.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:43&lt;br /&gt;
|| Your completed assignment may look similar to this.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:48&lt;br /&gt;
|| This video summarizes the '''Spoken Tutorial Project'''.&lt;br /&gt;
&lt;br /&gt;
Please download and watch it.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 09:56&lt;br /&gt;
|| The '''Spoken Tutorial Project''' team:  conducts workshops and gives certificates.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 10:03&lt;br /&gt;
||For more details, please write to us.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 10:07&lt;br /&gt;
|| Please post your timed queries in this forum.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 10:11&lt;br /&gt;
|| Spoken Tutorial Project is funded by '''NMEICT, MHRD''', Government of India.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 10:19&lt;br /&gt;
|| More information on this mission is available at this link.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|| 10:24&lt;br /&gt;
|| This is Rani from '''IIT Bombay'''. Thank you for joining.&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
|}­&lt;/div&gt;</summary>
		<author><name>PoojaMoolya</name></author>	</entry>

	</feed>