<?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: Quantiles with missing values in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392662#M64286</link>
    <description>&lt;P&gt;See for yourself.&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 = New Table( "Untitled 2",
	Add Rows( 10 ),
	New Column( "Full",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values( [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] )
	),
	New Column( "Partial",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values( [1, 2, 3, 4, 5, 6, 7, ., ., .] )
	)
);

values = :full &amp;lt;&amp;lt; Get As Matrix;
Show( Quantile( 0.1, values ) );

values = :Partial &amp;lt;&amp;lt; Get As Matrix;
Show( Quantile( 0.1, values ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The presence of missing values changes the sample quantile, so it will of curse change the rows that are selected.&lt;/P&gt;</description>
    <pubDate>Fri, 11 Jun 2021 12:43:22 GMT</pubDate>
    <dc:creator>Mark_Bailey</dc:creator>
    <dc:date>2021-06-11T12:43:22Z</dc:date>
    <item>
      <title>Quantiles with missing values</title>
      <link>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392595#M64281</link>
      <description>&lt;P&gt;If I have a column named X with 100 values which is a sequence from {1-100}, and I want to retrieve the 10 smallest values, I know I can use the command below:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dt = current data table();
temp1 = dt:X &amp;lt;&amp;lt; get values;
temp2 = quantile(0.1,temp1);
dt &amp;lt;&amp;lt; get rows where(:X&amp;lt;temp2);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Let's say I'm replacing the 10 largest values (i.e. 91-100) with missing values, is there a way to get the same 10 smallest values ? I believe the Quantile function will not take consideration of the missing values.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Appreciate the help&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 19:49:19 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392595#M64281</guid>
      <dc:creator>Djtjhin</dc:creator>
      <dc:date>2023-06-09T19:49:19Z</dc:date>
    </item>
    <item>
      <title>Re: Quantiles with missing values</title>
      <link>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392657#M64285</link>
      <description>&lt;P&gt;Do you want to get the rows or values? Here is one example how you should be able to get 10 smallest non missing values&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;temp1 = Sort Ascending(dt:X &amp;lt;&amp;lt; get values); //get values in column Value
temp1 = temp1[Loc(temp1)]; //ignore missing
tensmallest = temp1[1::10]; //get 10 first values in list&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 11 Jun 2021 12:42:21 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392657#M64285</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2021-06-11T12:42:21Z</dc:date>
    </item>
    <item>
      <title>Re: Quantiles with missing values</title>
      <link>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392662#M64286</link>
      <description>&lt;P&gt;See for yourself.&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 = New Table( "Untitled 2",
	Add Rows( 10 ),
	New Column( "Full",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values( [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] )
	),
	New Column( "Partial",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values( [1, 2, 3, 4, 5, 6, 7, ., ., .] )
	)
);

values = :full &amp;lt;&amp;lt; Get As Matrix;
Show( Quantile( 0.1, values ) );

values = :Partial &amp;lt;&amp;lt; Get As Matrix;
Show( Quantile( 0.1, values ) );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The presence of missing values changes the sample quantile, so it will of curse change the rows that are selected.&lt;/P&gt;</description>
      <pubDate>Fri, 11 Jun 2021 12:43:22 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392662#M64286</guid>
      <dc:creator>Mark_Bailey</dc:creator>
      <dc:date>2021-06-11T12:43:22Z</dc:date>
    </item>
    <item>
      <title>Re: Quantiles with missing values</title>
      <link>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392696#M64289</link>
      <description>This works for the solution that I was working on. Thanks!</description>
      <pubDate>Fri, 11 Jun 2021 14:45:43 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Quantiles-with-missing-values/m-p/392696#M64289</guid>
      <dc:creator>Djtjhin</dc:creator>
      <dc:date>2021-06-11T14:45:43Z</dc:date>
    </item>
  </channel>
</rss>

