Difference between revisions of "SampleVariance Command"

From GeoGebra Manual
Jump to: navigation, search
m (Text replace - ";(.*)\[(.*)\]" to ";$1($2)")
(Changed last example with un-reserved variables + command syntax: changed [ ] into ( ))
 
Line 2: Line 2:
 
;SampleVariance( <List of Raw Data> )
 
;SampleVariance( <List of Raw Data> )
 
:Returns the [[w:Sample_variance#Population_variance_and_sample_variance|sample variance]] of given list of numbers.
 
:Returns the [[w:Sample_variance#Population_variance_and_sample_variance|sample variance]] of given list of numbers.
:{{example|1=<div><code><nowiki>SampleVariance[ {1, 2, 3, 4, 5} ]</nowiki></code> yields ''a = 2.5''.</div>}}
+
:{{example|1=<code><nowiki>SampleVariance({1, 2, 3, 4, 5})</nowiki></code> yields ''a = 2.5''.}}
  
  
 
; SampleVariance( &lt;List of Numbers>, &lt;List of Frequencies> )
 
; SampleVariance( &lt;List of Numbers>, &lt;List of Frequencies> )
 
:Returns the [[w:Sample_variance#Population_variance_and_sample_variance|sample variance]] of given list of numbers considering the frequencies.
 
:Returns the [[w:Sample_variance#Population_variance_and_sample_variance|sample variance]] of given list of numbers considering the frequencies.
:{{example|1=<div><code><nowiki>SampleVariance[ {1, 2, 3, 4, 5}, {3, 2, 4, 4, 1} ]</nowiki></code> yields ''a = 1.67''.</div>}}
+
:{{example|1=<code><nowiki>SampleVariance({1, 2, 3, 4, 5}, {3, 2, 4, 4, 1})</nowiki></code> yields ''a = 1.67''.}}
  
  
 
{{hint|1=
 
{{hint|1=
 
If the list in the [[File:Menu view spreadsheet.svg|link=|16px]] [[CAS View]] contains undefined variables, this command yields a formula for the sample variance.
 
If the list in the [[File:Menu view spreadsheet.svg|link=|16px]] [[CAS View]] contains undefined variables, this command yields a formula for the sample variance.
: {{example|1=<div><code><nowiki>SampleVariance[ {x, y, z} ]</nowiki></code> yields <math>\frac{1}{3} x^{2} - \frac{1}{3} x y - \frac{1}{3}xz + \frac{1}{3} y^{2} - \frac{1}{3} y z + \frac{1}{3} z^{2}</math>.</div>}}
+
: {{example|1=<code><nowiki>SampleVariance({a, b, c})</nowiki></code> yields <math>\frac{1}{3} a^{2} - \frac{1}{3} ab - \frac{1}{3}ac + \frac{1}{3} b^{2} - \frac{1}{3} bc + \frac{1}{3} c^{2}</math>.}}
 
}}
 
}}

Latest revision as of 10:07, 12 October 2017


SampleVariance( <List of Raw Data> )
Returns the sample variance of given list of numbers.
Example: SampleVariance({1, 2, 3, 4, 5}) yields a = 2.5.


SampleVariance( <List of Numbers>, <List of Frequencies> )
Returns the sample variance of given list of numbers considering the frequencies.
Example: SampleVariance({1, 2, 3, 4, 5}, {3, 2, 4, 4, 1}) yields a = 1.67.


Note Hint: If the list in the Menu view spreadsheet.svg CAS View contains undefined variables, this command yields a formula for the sample variance.
Example: SampleVariance({a, b, c}) yields \frac{1}{3} a^{2} - \frac{1}{3} ab - \frac{1}{3}ac + \frac{1}{3} b^{2} - \frac{1}{3} bc + \frac{1}{3} c^{2}.
© 2024 International GeoGebra Institute