<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Populating the data in new table with variable defined in script in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211526#M42375</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;
&lt;P&gt;Actually i am trying to perform a calculation in jmp script, i have defined these calculation using a variable. ( ie- a,b etc), now i trying to populate this variable into a new table, such that each time if input changes , calculation will change and new data will be populated in new table.&lt;/P&gt;
&lt;P&gt;let us assume a= weibull function( consider every input i have for calculating a)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = New Table( "Result", 
	New Column( "X", 
		Expression, 
		"Nominal",
		Set Values( {a} )
	)
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;in new table i am getting output as &lt;STRONG&gt;a&lt;/STRONG&gt;, not the value of &lt;STRONG&gt;a. &lt;/STRONG&gt;i want value of &lt;STRONG&gt;a&lt;/STRONG&gt; to be populated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Dilip&lt;/P&gt;</description>
    <pubDate>Mon, 03 Jun 2019 12:32:24 GMT</pubDate>
    <dc:creator>dilipkumar</dc:creator>
    <dc:date>2019-06-03T12:32:24Z</dc:date>
    <item>
      <title>Populating the data in new table with variable defined in script</title>
      <link>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211526#M42375</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;
&lt;P&gt;Actually i am trying to perform a calculation in jmp script, i have defined these calculation using a variable. ( ie- a,b etc), now i trying to populate this variable into a new table, such that each time if input changes , calculation will change and new data will be populated in new table.&lt;/P&gt;
&lt;P&gt;let us assume a= weibull function( consider every input i have for calculating a)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = New Table( "Result", 
	New Column( "X", 
		Expression, 
		"Nominal",
		Set Values( {a} )
	)
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;in new table i am getting output as &lt;STRONG&gt;a&lt;/STRONG&gt;, not the value of &lt;STRONG&gt;a. &lt;/STRONG&gt;i want value of &lt;STRONG&gt;a&lt;/STRONG&gt; to be populated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Dilip&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jun 2019 12:32:24 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211526#M42375</guid>
      <dc:creator>dilipkumar</dc:creator>
      <dc:date>2019-06-03T12:32:24Z</dc:date>
    </item>
    <item>
      <title>Re: Populating the data in new table with variable defined in script</title>
      <link>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211559#M42379</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/12440"&gt;@dilipkumar&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Not knowing what the variables (a, b, etc.) might contain, here are two examples if the variables contain a list or a function, that will populate the column with the values defined by the variable and not the variable itself,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = New Table( "Result" );

// Method for inserting a list or a matrix
a = [1, 2, 3, 4];
dt &amp;lt;&amp;lt; New Column( "X", Continuous, "Nominal", Set Values( a ) );


// Method for inserting a function
b = Expr(
	Random Uniform( 1, 10 )
);
dt &amp;lt;&amp;lt; New Column( "Y", continuous, "nominal", formula( Name Expr( b ) ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Hope that helps.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jun 2019 13:07:36 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211559#M42379</guid>
      <dc:creator>Ryan_Gilmore</dc:creator>
      <dc:date>2019-06-03T13:07:36Z</dc:date>
    </item>
    <item>
      <title>Re: Populating the data in new table with variable defined in script</title>
      <link>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211577#M42383</link>
      <description>My variable is function, it return some values,&lt;BR /&gt;i tried using your second example, i am getting empty data table named " Result"&lt;BR /&gt;</description>
      <pubDate>Mon, 03 Jun 2019 14:03:31 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211577#M42383</guid>
      <dc:creator>dilipkumar</dc:creator>
      <dc:date>2019-06-03T14:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: Populating the data in new table with variable defined in script</title>
      <link>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211584#M42384</link>
      <description>&lt;P&gt;I think you may need to add some rows the table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = New Table( "Result" );

// Method for inserting a function
b = Expr(
	Random Uniform( 1, 10 )
);
dt &amp;lt;&amp;lt; New Column( "Y", continuous, "nominal", formula( Name Expr( b ) ) );

dt &amp;lt;&amp;lt; add row( 5 );
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;In the first example, setting the values of column X automatically generated the rows.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jun 2019 14:34:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populating-the-data-in-new-table-with-variable-defined-in-script/m-p/211584#M42384</guid>
      <dc:creator>Ryan_Gilmore</dc:creator>
      <dc:date>2019-06-03T14:34:50Z</dc:date>
    </item>
  </channel>
</rss>

