<?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 How to input multiple inputs to multiple models? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/373707#M62341</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Imagine I have 15 independent sets of data pairs (0,b1) to (10,z1), (0,b2) to (10,z2)......all the way to (0,b15) to (10,z15). Imagine that for each pair, the first data point is at 0 hours, the second is at 10 hours.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then, I have another 15 independent sets of data that have different values, but the same concept as above. Let us assume the first 15 set is "before" and the second 15 set is "after".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1) For "before", I want get 15 line of best fit between the two points of each of my 15 sets. I want to be able to input 4 hours and have the line of best fit model spit out the predicted response. So end result should be 15 outputs at 4 hours. I know how to output a predicted model column for ONE model, but i don't know about MANY models at once?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Then, I want to make 15 line of best fits for each of the "after". Finally, I want to put each of the 15 outputs from step 1) into each output from my line models from 2), and get 255 different inputs (hours) result...I should get 15 x 15 = 255 predicted hours.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is this possible with JMP?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 10 Jun 2023 23:28:08 GMT</pubDate>
    <dc:creator>schou1994</dc:creator>
    <dc:date>2023-06-10T23:28:08Z</dc:date>
    <item>
      <title>How to input multiple inputs to multiple models?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/373707#M62341</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Imagine I have 15 independent sets of data pairs (0,b1) to (10,z1), (0,b2) to (10,z2)......all the way to (0,b15) to (10,z15). Imagine that for each pair, the first data point is at 0 hours, the second is at 10 hours.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then, I have another 15 independent sets of data that have different values, but the same concept as above. Let us assume the first 15 set is "before" and the second 15 set is "after".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1) For "before", I want get 15 line of best fit between the two points of each of my 15 sets. I want to be able to input 4 hours and have the line of best fit model spit out the predicted response. So end result should be 15 outputs at 4 hours. I know how to output a predicted model column for ONE model, but i don't know about MANY models at once?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Then, I want to make 15 line of best fits for each of the "after". Finally, I want to put each of the 15 outputs from step 1) into each output from my line models from 2), and get 255 different inputs (hours) result...I should get 15 x 15 = 255 predicted hours.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is this possible with JMP?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 10 Jun 2023 23:28:08 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/373707#M62341</guid>
      <dc:creator>schou1994</dc:creator>
      <dc:date>2023-06-10T23:28:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to input multiple inputs to multiple models?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/373931#M62360</link>
      <description>&lt;P&gt;Yes, I think it is. Or what more answer did you expect by this question?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In JMP you can realize almost everything by scripting.&lt;/P&gt;&lt;P&gt;And interactively you can e.g. using the by role for fitting different models on different sets.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But to get the help you want, I think you need to be more specific and give us an example of your datastructure, how it looks like.&lt;/P&gt;&lt;P&gt;Perhaps the enclosed script helps you to do the first step, fitting the model for several datasets in a table.&lt;/P&gt;&lt;P&gt;Than of course you can drag out the model,&lt;/P&gt;&lt;P&gt;and deploy it to other data ...&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;Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );

dt &amp;lt;&amp;lt; Bivariate(
	SendToByGroup( {:sex == "F"} ),
	Y( :weight ),
	X( :height ),
	Fit Line( {Line Color( {33, 116, 145} )} ),
	By( :sex ),
	SendToByGroup(
		{:sex == "F"},
		SendToReport(
			Dispatch(
				{"Bivariate Fit of weight By height sex=F"},
				"Linear Fit",
				OutlineBox,
				{Close( 1 )}
			)
		)
	),
	SendToByGroup(
		{:sex == "M"},
		SendToReport(
			Dispatch(
				{"Bivariate Fit of weight By height sex=M"},
				"Linear Fit",
				OutlineBox,
				{Close( 1 )}
			)
		)
			
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 02 Apr 2021 15:08:08 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/373931#M62360</guid>
      <dc:creator>Georg</dc:creator>
      <dc:date>2021-04-02T15:08:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to input multiple inputs to multiple models?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/374608#M62438</link>
      <description>&lt;P&gt;I agree with&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/9474"&gt;@Georg&lt;/a&gt;&amp;nbsp;that you are going to need a scripting solution.&amp;nbsp; You could write or save a script to perform the function you mentioned for a single variable, and then introduce loops to perform that same script for every other variable.&amp;nbsp; The scripting guide will be a great resource to help you get started.&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;indvars = {:x1, :x2, :x3};
depvars = {:y1, :y2, :y3};
for( i = 1, i &amp;lt;= n items( indvars ), i++,
	for( d = 1, d &amp;lt;= n items( depvars ), d++,
		fm = Fit Model(
			//the script to fit your model goes here
		);
		fm &amp;lt;&amp;lt; Save Prediction Formula; // this would depend which platform you use
		fm &amp;lt;&amp;lt; close Window;
	)
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 06 Apr 2021 12:43:04 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-input-multiple-inputs-to-multiple-models/m-p/374608#M62438</guid>
      <dc:creator>ih</dc:creator>
      <dc:date>2021-04-06T12:43:04Z</dc:date>
    </item>
  </channel>
</rss>

