<?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: Create 1000 columns with similar formulas at one run in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761987#M94016</link>
    <description>&lt;P&gt;If you really need formulas and not just values, here is one option&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

dt = New Table("test",
	Add Rows(2),
	New Column("ColumnA", Numeric, Continuous, Values([1, 2])),
	Invisible // open/create as invisible! (or make invisible)
);

For(i = 1, i &amp;lt;= 1000, i++,
	Eval(EvalExpr(
		dt &amp;lt;&amp;lt; New Column("ColumnA+"||Char(i), Numeric, Continuous, Formula(
			:ColumnA + Expr(i)
		))
	));
);

dt &amp;lt;&amp;lt; Show Window(1); // if you need table visible later&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If speed is important using Invisible is one thing you can do.&lt;/P&gt;</description>
    <pubDate>Wed, 29 May 2024 15:30:55 GMT</pubDate>
    <dc:creator>jthi</dc:creator>
    <dc:date>2024-05-29T15:30:55Z</dc:date>
    <item>
      <title>Create 1000 columns with similar formulas at one run</title>
      <link>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761986#M94015</link>
      <description>&lt;P&gt;I have an input column (ColumnA) that essentially has the Index of the table. I want to add 1000 numeric columns to this table. Each of the columns will add the column number to the original column.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Example: the first new column will have the formula, ColumnA+1.&amp;nbsp;&lt;/P&gt;&lt;P&gt;30th new column will have the formula, ColumnA+30.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2024 15:20:45 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761986#M94015</guid>
      <dc:creator>AsymptoticCos</dc:creator>
      <dc:date>2024-05-29T15:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: Create 1000 columns with similar formulas at one run</title>
      <link>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761987#M94016</link>
      <description>&lt;P&gt;If you really need formulas and not just values, here is one option&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

dt = New Table("test",
	Add Rows(2),
	New Column("ColumnA", Numeric, Continuous, Values([1, 2])),
	Invisible // open/create as invisible! (or make invisible)
);

For(i = 1, i &amp;lt;= 1000, i++,
	Eval(EvalExpr(
		dt &amp;lt;&amp;lt; New Column("ColumnA+"||Char(i), Numeric, Continuous, Formula(
			:ColumnA + Expr(i)
		))
	));
);

dt &amp;lt;&amp;lt; Show Window(1); // if you need table visible later&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If speed is important using Invisible is one thing you can do.&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2024 15:30:55 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761987#M94016</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2024-05-29T15:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: Create 1000 columns with similar formulas at one run</title>
      <link>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761991#M94018</link>
      <description>&lt;P&gt;1. &amp;nbsp;make 100 columns.&lt;/P&gt;
&lt;P&gt;2. select all 100 columns&lt;/P&gt;
&lt;P&gt;3. Cols&amp;gt;Standardize attibutes&lt;/P&gt;
&lt;P&gt;4. Add a formula column property from the properties dropdown.&lt;/P&gt;
&lt;P&gt;5. Edit the formula, put in your formula, and click OK in the formula editor&lt;/P&gt;
&lt;P&gt;6. Finally click ok (top right of standardize attributes window)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;but I'm not sure that's what you really want to do&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2024 15:38:45 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Create-1000-columns-with-similar-formulas-at-one-run/m-p/761991#M94018</guid>
      <dc:creator>Byron_JMP</dc:creator>
      <dc:date>2024-05-29T15:38:45Z</dc:date>
    </item>
  </channel>
</rss>

