<?xml version="1.0" encoding="UTF-8"?>

<!--
 *
 * This help file was generated from distfun_nctrnd.sci using help_from_sci().
 *
 -->

<refentry version="5.0-subset Scilab" xml:id="distfun_nctrnd" xml:lang="en"
          xmlns="http://docbook.org/ns/docbook"
          xmlns:xlink="http://www.w3.org/1999/xlink"
          xmlns:svg="http://www.w3.org/2000/svg"
          xmlns:ns3="http://www.w3.org/1999/xhtml"
          xmlns:mml="http://www.w3.org/1998/Math/MathML"
          xmlns:scilab="http://www.scilab.org"
          xmlns:db="http://docbook.org/ns/docbook">

  <refnamediv>
    <refname>distfun_nctrnd</refname>
    <refpurpose>Noncentral T random numbers</refpurpose>
  </refnamediv>


<refsynopsisdiv>
   <title>Calling Sequence</title>
   <synopsis>
   x = distfun_nctrnd ( v , delta )
   x = distfun_nctrnd ( v , delta , [m,n] )
   x = distfun_nctrnd ( v , delta , m , n )
   
   </synopsis>
</refsynopsisdiv>

<refsection>
   <title>Parameters</title>
   <variablelist>
   <varlistentry><term>v :</term>
      <listitem><para> a matrix of doubles, the number of degrees of freedom, v>0.</para></listitem></varlistentry>
   <varlistentry><term>delta :</term>
      <listitem><para> a matrix of doubles, the noncentrality parameter, delta is real</para></listitem></varlistentry>
   <varlistentry><term>m :</term>
      <listitem><para> a 1-by-1 matrix of floating point integers, the number of rows of x</para></listitem></varlistentry>
   <varlistentry><term>n :</term>
      <listitem><para> a 1-by-1 matrix of floating point integers, the number of columns of x</para></listitem></varlistentry>
   <varlistentry><term>x:</term>
      <listitem><para> a matrix of doubles, the random numbers, in the interval [0,1].</para></listitem></varlistentry>
   </variablelist>
</refsection>

<refsection>
   <title>Description</title>
   <para>
Generates random variables from the Noncentral T distribution.
   </para>
   <para>
Any scalar input argument is expanded to a matrix of doubles
of the same size as the other input arguments.
   </para>
   <para>
</para>
</refsection>

<refsection>
   <title>Examples</title>
   <programlisting role="example"><![CDATA[
// Produce 6 random numbers from Noncentral T distribution
// and degrees of freedom from 1 to 6,
// with noncentrality parameter equal to 12
x=distfun_nctrnd(1:6,12)

// Compare empirical distribution and density
v=12;
delta=3;
N=10000;
h=scf();
x=distfun_nctrnd(v,delta,1,N);
histplot(40,x);
h.children.children(1).children.background=-2;
[M,V]=distfun_nctstat(v,delta);
x=linspace(M-3*sqrt(V),M+3*sqrt(V),1000);
y=distfun_nctpdf(x,v,delta);
plot(x,y,"r-");
xtitle("Noncentral T Random Numbers","X","Frequency")
legend(["Empirical","Density"]);

   ]]></programlisting>
</refsection>

<refsection>
   <title>Authors</title>
   <simplelist type="vert">
   <member>Copyright (C) 2014 - Michael Baudin</member>
   </simplelist>
</refsection>
</refentry>
