Displaying 2 results from an estimated 2 matches for "upnum".
Did you mean:
pnum
2006 Aug 07
1
mathematica -> r (gamma function + integration)
Dear R-list,
I try to transform a mathematica script to R.
#######relevant part of the Mathematica script
(* p_sv *)
dd = NN (DsD - DD^2);
lownum = NN (L-DD)^2;
upnum = NN (H-DD)^2;
low = lownum/(2s^2);
up = upnum/(2s^2);
psv = NIntegrate[1/(s^NN) Exp[-dd/(2s^2)]
(Gamma[1/2,0,up] + Gamma[1/2,0,low]),{s,sL,sH},
MinRecursion->3];
PSV = psv/Sqrt[2NN];
Print["------------- Results ------------------------------------"];
Print[" "];
P...
2006 Sep 01
1
integration problem with gamma function
...-------------------------------------
# Begin: ON THE DIFFERENCE IN MEANS
# --------------------------------------------------
#DiffinMeans <- function(Ni, Di, si, Nii, Dii, sii, L, H, sL, sH)
## BEGIN BLOCK
#{
# necessary variables in the function
#{ NN, DD, Dsi, Dsii, DsD, ss,
# dd, lownum, upnum, low, up, psv, PSV,
# zz, lowinum, upinum, lowiinum, upiinum, psbarv, PSbarV,
# psvbar, PSVbar, psbarvbar, PSbarVbar, cc,
# sv, sbarv, svbar, sbarvbar,
# samemeans, diffmeans, samevars, diffvars, diffsets },
### defintion of constants
NN <- Ni+Nii
DD <- (Ni * Di + Nii * Dii) / NN
Dsi &...