<?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 Re: Update column with formula in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/762057#M94054</link>
    <description>&lt;P&gt;I had a similar problem using concatenate.&amp;nbsp; The combined table had entries for the original table but not the table of new rows.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The solution was to check the box "Save and evaluate formulas".&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is much easier than adding the formula columns to the table of new rows before concatenating.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rob.&lt;/P&gt;</description>
    <pubDate>Thu, 30 May 2024 18:53:52 GMT</pubDate>
    <dc:creator>owg</dc:creator>
    <dc:date>2024-05-30T18:53:52Z</dc:date>
    <item>
      <title>Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463666#M70829</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I have two data table (dt1 &amp;amp; dt2). I need to add dt2's column (Col1) to dt1 with a formula in it. But when I update the table, the values from Col1 are empty. Seems to be a problem in the formula. Please help&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;current data table (dt1); 				
dt1 &amp;lt;&amp;lt; Update( With( dt2), Match Columns( :KeySample= :KeySample), Add Columns from Update table ( :Col1) );
dt1:Remarks &amp;lt;&amp;lt; Formula ( If( :Col1== "Out of Range", "Out of Range", "" ));
	&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 10 Jun 2023 23:44:41 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463666#M70829</guid>
      <dc:creator>UserID16644</dc:creator>
      <dc:date>2023-06-10T23:44:41Z</dc:date>
    </item>
    <item>
      <title>Re: Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463706#M70830</link>
      <description>&lt;P&gt;I am not finding an error with your code.&amp;nbsp; I adopted it to a couple of sample data tables that I have attached, and it works without error.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="txnelson_0-1645667853168.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/40278i84A75EDF46D7F73D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="txnelson_0-1645667853168.png" alt="txnelson_0-1645667853168.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;names default to here(1);
dt1=data table ("bc1");
dt2=data table("bc2"); 				
dt1 &amp;lt;&amp;lt; Update( With( dt2), Match Columns( :name= :name, :sex==:sex),
 Add Columns from Update table ( :Age) );
dt1:Remarks &amp;lt;&amp;lt; Formula ( If( :age== "12", "Out of Range", "" ));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Check to make sure that my code works on your copy of JMP.&amp;nbsp; If it does(which it should) then look to see how my sample data table's columns are different from your tables.&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 01:59:54 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463706#M70830</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-02-24T01:59:54Z</dc:date>
    </item>
    <item>
      <title>Re: Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463707#M70831</link>
      <description>&lt;P&gt;&amp;nbsp;Hi txnelson, from my example, the added column also has a formula which will become blank after update. I also tried delete formula before updating the table, but still, the column is blank&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 02:57:24 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463707#M70831</guid>
      <dc:creator>UserID16644</dc:creator>
      <dc:date>2022-02-24T02:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463711#M70833</link>
      <description>&lt;P&gt;Can you attach some samples of the data tables?&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 04:25:34 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463711#M70833</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-02-24T04:25:34Z</dc:date>
    </item>
    <item>
      <title>Re: Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463712#M70834</link>
      <description>&lt;P&gt;Try Copy column properties from dt1, then past column properties to dt2. When use update table, the formula got lost.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names default to here(1);

// → Data Table( "Big Class" )
dt1=Open( "$SAMPLE_DATA/Big Class.jmp" );
// Launch platform: Bivariate
Biv= dt1&amp;lt;&amp;lt;Bivariate( Y( :weight ), X( :height ), Fit Line(1) );

Biv &amp;lt;&amp;lt; (Curve["Linear Fit"] &amp;lt;&amp;lt; Save Predicteds);

dt2 = New Table( "New ht",
	New Column( "height", numeric, continuous, set values([59,75]) ),
	New Column( "weight", numeric, continuous ),	
);

dt1 &amp;lt;&amp;lt; Copy Column Properties ({:Predicted weight});
dt2 &amp;lt;&amp;lt; Paste Column Properties ({: weight});

// Update data tables lose formula
dt2 &amp;lt;&amp;lt; Update(
	With( dt1 ),
	Match Columns( :height = :height ),
	Add Columns from Update Table( :Predicted weight ),
	Replace Columns in Main Table( None )
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 24 Feb 2022 05:11:15 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/463712#M70834</guid>
      <dc:creator>ZF</dc:creator>
      <dc:date>2022-02-24T05:11:15Z</dc:date>
    </item>
    <item>
      <title>Re: Update column with formula</title>
      <link>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/762057#M94054</link>
      <description>&lt;P&gt;I had a similar problem using concatenate.&amp;nbsp; The combined table had entries for the original table but not the table of new rows.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The solution was to check the box "Save and evaluate formulas".&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is much easier than adding the formula columns to the table of new rows before concatenating.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rob.&lt;/P&gt;</description>
      <pubDate>Thu, 30 May 2024 18:53:52 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Update-column-with-formula/m-p/762057#M94054</guid>
      <dc:creator>owg</dc:creator>
      <dc:date>2024-05-30T18:53:52Z</dc:date>
    </item>
  </channel>
</rss>

