<?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: how do I write a script to compute confidence intervals in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/457137#M70236</link>
    <description>&lt;P&gt;Perfect.&amp;nbsp; Thank you!&lt;/P&gt;</description>
    <pubDate>Mon, 31 Jan 2022 12:40:43 GMT</pubDate>
    <dc:creator>learning_JSL</dc:creator>
    <dc:date>2022-01-31T12:40:43Z</dc:date>
    <item>
      <title>how do I write a script to compute confidence intervals</title>
      <link>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/454039#M70074</link>
      <description>&lt;P&gt;Hi - I am still new at jsl scripting and am trying to write a script that creates and&amp;nbsp;saves four new columns based on my linear regression fit:&lt;/P&gt;&lt;P&gt;- lower 95% mean confidence interval&lt;/P&gt;&lt;P&gt;- upper 95% mean confidence interval&lt;/P&gt;&lt;P&gt;-&amp;nbsp;lower 95% individual confidence interval&lt;/P&gt;&lt;P&gt;- upper 95% individual confidence interval&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;obj = Fit Model(
	Y( :LOG_ECOLI_PEAR ),
	Effects( :LOG_TURB_PEAR_FNU),
	Personality( "Standard Least Squares" ),
	Emphasis( "Effect Leverage" ),
	Run(:LOG_ECOLI_PEAR 
	))	;
 
  obj &amp;lt;&amp;lt; Prediction Formula;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 18:09:33 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/454039#M70074</guid>
      <dc:creator>learning_JSL</dc:creator>
      <dc:date>2023-06-09T18:09:33Z</dc:date>
    </item>
    <item>
      <title>Re: how do I write a script to compute confidence intervals</title>
      <link>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/454885#M70135</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/31342"&gt;@learning_JSL&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; It's actually really easy. All you need to do is add a few lines of code to your existing JSL and you're done. While you're at it, I highly suggest using the Scripting Index under the Help menu -- it's VERY useful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; For the mean CI, you'll add the code: obj &amp;lt;&amp;lt; Mean Confidence Interval; and for the individual CIs, you'll add obj &amp;lt;&amp;lt; Indiv Confidence Interval;. The default is for an alpha of 0.05 (corresponding to your +/- 95%, but you can specify any alpha you want, for example: obj &amp;lt;&amp;lt; Mean Confidence Interval(0.1) would correspond to +/-90% CIs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Below is some code you can try out using the Diabetes.jmp file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps!,&lt;/P&gt;&lt;P&gt;DS&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names default to here(1);

dt=Open("$SAMPLE_DATA/Diabetes.jmp");

obj_fit = Fit Model(
	Validation( :Validation ),
	Y( :Y ),
	Effects(
		:Age, :Gender, :BMI, :BP, :Total Cholesterol, :LDL, :HDL, :TCH, :LTG,
		:Glucose
	),
	Personality( "Standard Least Squares" ),
	Emphasis( "Effect Leverage" ),
	Run(
		:Y &amp;lt;&amp;lt; {Summary of Fit( 1 ), Analysis of Variance( 1 ),
		Parameter Estimates( 1 ), Lack of Fit( 0 ), Scaled Estimates( 0 ),
		Plot Actual by Predicted( 1 ), Plot Regression( 0 ),
		Plot Residual by Predicted( 1 ), Plot Studentized Residuals( 0 ),
		Plot Effect Leverage( 1 ), Plot Residual by Normal Quantiles( 0 ),
		Box Cox Y Transformation( 0 )}
	)
);

obj_fit &amp;lt;&amp;lt; Prediction Formula;
obj_fit &amp;lt;&amp;lt; Mean Confidence Interval;
obj_fit &amp;lt;&amp;lt; Indiv Confidence Interval;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 26 Jan 2022 19:05:30 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/454885#M70135</guid>
      <dc:creator>SDF1</dc:creator>
      <dc:date>2022-01-26T19:05:30Z</dc:date>
    </item>
    <item>
      <title>Re: how do I write a script to compute confidence intervals</title>
      <link>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/457137#M70236</link>
      <description>&lt;P&gt;Perfect.&amp;nbsp; Thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 31 Jan 2022 12:40:43 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/how-do-I-write-a-script-to-compute-confidence-intervals/m-p/457137#M70236</guid>
      <dc:creator>learning_JSL</dc:creator>
      <dc:date>2022-01-31T12:40:43Z</dc:date>
    </item>
  </channel>
</rss>

