Questions on the statistical functions of Mathematica.

learn more… | top users | synonyms

4
votes
1answer
164 views

Defining five-parameter Pearson distribution by moments

How do you derive (or where can I find a derivation of) the equations to match the five parameters of a general Pearson distribution to a mean, variance, skewness, kurtosis, and condition that the ...
3
votes
3answers
413 views

Log-log scale smooth histogram

How can I create a smooth histogram with a log-log scale? I can use Histogram[data, "Log", "LogCount"] to get a log-log histogram, or I can use ...
3
votes
1answer
130 views

How to Use ProbabilityScalePlot with Censored Data?

I am trying to reproduce a ProbabilityScalePlot of censored data shown here (see Sample Analysis Plot). Here is my Mathematica code. First I deal with the uncensored case. ...
6
votes
1answer
516 views

How do I calculate Standard Deviation confidence intervals in Mathematica?

I have a series of simulation results and I would like to demonstrate how the confidence interval for the mean and standard deviation decrease as the number of results increases. I have done this for ...
3
votes
1answer
164 views

DistributionFitTest with WeightedData?

My problem is related to statistical testing with weighted data. I have a data sample and I assume that a part of the data follows a specific distribution (Pareto). So I fit my data to a distribution ...
5
votes
1answer
668 views

Hodrick–Prescott filter (one-sided version)

I am interested in implementing Hodrick–Prescott filter (HP filter) on my time series data in Mathematica. I know that there is already a version of two-sided original filter for Mathematica (see ...
3
votes
4answers
218 views

Descriptive statistics of two events

I am trying to use the descriptive statistics feature of Mathematica to answer the following question: suppose I have two events, A and B, whose occurrence is described by a normal distribution around ...
4
votes
1answer
360 views

Using DistributionFitTest on custom distributions in Mathematica 8

I originally posted this question on Stack Overflow, but I didn't get any answers, and I'm hoping to have better luck here. I'm trying to compute the goodness-of-fit of a bi-modal Gaussian ...
2
votes
1answer
97 views

Confidence level for Binomial

For 617519 first time births there were 317528 boys. Give an estimate with 99% confidence interval for the probability that the first time birth is a boy. I have searched for the confidence ...
1
vote
1answer
128 views

Value for x such that |(x-y)| is minimum

I have a list Y={y1,y2,y3,...,yn} And I would need to find x such that Abs[x-Y[[i]]] for all $y_i$ in $Y$ is minimum. ...
6
votes
3answers
428 views

Calculate probability function

I would like to calculate the following with Mathematica: Let $X$ be a random variable with probability function $$p(x)= \left\{ \begin{matrix} \frac{x}{6} & \text{for }x \in \{1,2,3\}\\ 0 ...
13
votes
1answer
231 views

Randomness test suites that can be invoked from Mathematica

There are several test suites referenced at csrc.nist.gov designed to test a (pseudo-)random byte sequence for randomness, and discover possible skews, correlations, patterns, or other hidden ...
4
votes
2answers
323 views

How to make a conditioning plot?

I'd like to make a conditioning plot just like coplot in R. Is there a pre-made solution or do I have to make a bunch of plots individually? Edit: This is an example from r screenshots. It is a way ...
1
vote
0answers
575 views

How to Output Chi-Squared Statistics when using NonLinearModelFit

I am using NonLinearModelFit for some curve fitting and I was wondering if NLM is able to output chi-squared/leastsquared statistics from the best-fit parameters and confidence intervals. From my ...
0
votes
1answer
141 views

plot probability

Hi I just want to flatten a function, I tied it with Joined->True, but it did not work, hope somebody of you can help me. This is my code: ...
2
votes
1answer
245 views

Problem with Covariance Matrix Output in NonlinearModelFit

I am running NonlinearModelFit based off of some simulated data and trying to fit to a function with more than one parameter. Eventually, I would like to fit to 5 ...
2
votes
0answers
45 views

How can I account for assumed X and Y errors when using findfit? [duplicate]

I'm using very noisy biological data, and I need to assume, when doing linear regression, that there are errors in both X and Y. ...
0
votes
0answers
101 views

Binomial Distribution (binomial model inspired by Merton)

Binomial Distribution (binomial model inspired by Merton) Hi I want to do the following and I hope that anyone of you can help me out. In short, I have a portfolio consisting of 10 companies, ...
17
votes
1answer
348 views
0
votes
2answers
596 views

How to generate a random data set with determined expected value and variance? [closed]

Recently I am doing my math homework and there is a question asking me to Come up with a dataset X that has at least 10 distinct numbers in it such that Expect[X] = 3.7, and Var[X] = 2.1. Actually I ...
1
vote
0answers
162 views

Simulations with MonteCarlo and Autoregressive methods

I am trying to find the best-fit trend for my data. Here I just generated it but let's say I don't know my data trend at all. ...
2
votes
0answers
573 views

Linear regression with x and y errors

I have a question about finding a linear regression weighted with x and y errors. I found the answer provided by 0x4A4D in Estimate error on slope of linear regression given data with associated ...
2
votes
1answer
347 views

Computing Correlations and p-values

I have two vectors $A$ and $B$ of length (say) $50$ or so, and I want to determine whether there is any correlation between their entries. I computed their correlation directly and found it to be ...
1
vote
0answers
61 views

Changing GeometricBrownianMotionProcess function

Since the function GeometricBrownianMotionProcess is given by Mathematica I have some technical questions. If we consider the following example: ...
8
votes
3answers
435 views

The default bandwidth of the SmoothKernelDistribution function

I am researching the Silverman rule of thumb for bandwidth selection. Below is a sample of my code, from which it seems that BW=63 is close to the default parameter given by Mathematica (2 images are ...
0
votes
0answers
371 views

Coefficient of determination (R squared) of EstimatedDistribution

I have estimated the distribution for a set of data as LogisticDistribution[3.5, 1.037]. How can I calculate and plot the coefficient of determination (R squared) ...
17
votes
3answers
3k views

Showing the correlation of two variables using a plot

I have a list of $\{x_i,y_i\}$ pairs and I want to show that $x_i$'s and $y_i$'s have positive correlation. The result of ...
2
votes
2answers
179 views

Stochastic problem

I have to organize a small sports league and I am puzzled on how to create the game plan. We are 8 persons playing table soccer with 2 vs. 2 matches. The idea is that each person plays once with ...
8
votes
2answers
522 views

How to define a new copula distribution family

The function CopulaDistribution can be used with the most well known kernels. I was wondering how I can add a new family of kernels in a way that it works in the ...
3
votes
1answer
422 views

How can I calculate the correlation dimension and/or the Lyapunov exponent of a time series using Mathematica

I have a pretty long time series (4000 data points). How can I calculate the Correlation dimension and/or Lyapunov exponent for such data? Please also advise on how to import the data as well.
7
votes
3answers
2k views

Doing a chi-square independence test in Mathematica

I have a matrix consisting of the following data: Needs["HypothesisTesting`"] data = {{11, 206}, {32, 1374}} How would I make a chi-square independence test ...
8
votes
1answer
196 views

CorrelationTest small bug?

Consider two Normally distributed random variables: x1 = RandomVariate[NormalDistribution[], {1000}]; x2 = RandomVariate[NormalDistribution[], {1000}]; I want to ...
4
votes
1answer
247 views

AR(1) Process first term

I'm trying to generate a very simple AR(1) Process with Mathematica using the ARProcess[] function. The process must have the following format: $Y_t = \alpha + ...
9
votes
3answers
473 views

Different calculation of median and quartiles, bug in BoxWhiskerChart?

When you plot a dataset with BoxWhiskerChart passing over the box in the plot with your mouse pointer shows some specifics about the dataset (min and max values, ...
10
votes
2answers
326 views

What do the options of SmoothKernelDistribution do?

The function SmoothKernelDistribution has three options that are not described in too much detail in the Mathematica's help window. InterpolationPoints: What is ...
1
vote
1answer
120 views

PDF on TransformedDistribution of two BinomialDistribution too slow

I'd been doing my own convolutions of distributions for some calculations, decided to use built-ins. With ...
16
votes
5answers
6k views

Estimate error on slope of linear regression given data with associated uncertainty

Given a set of data, is it possible to create a linear regression which has a slope error that takes into account the uncertainty of the data? This is for a high school class, and so the normal ...
1
vote
2answers
404 views

Probability density histogram with unequal bin widths

I am confused by output of Histogram and HistogramList for probability density ("PDF") when ...
2
votes
0answers
530 views

Calculate variance of random walk?

How can I symbolically calculate the variance of the following random walk in Mathematica? Given several discrete random variables such that $p(Z_i=1-2k)=p$, where $k$ is a small real number, and ...
7
votes
1answer
231 views

Overlay of pdf using PairedHistogram in Mathematica

With a standard 1D histogram, I can generate a pdf overlay using Show and Plot. I'd like to do something similar with ...
1
vote
0answers
288 views

Matrix algebra vs. PrincipalComponents and Varimax/Oblimin

Using matrix algebra I can calculate loadings and scores from the covariance matrix (data matrix is column centered): ...
2
votes
1answer
121 views

Standard Deviation and StandardDeviationFilter

I found this scant description of StandardDeviationFilter in the documentation, implying one could use it to generate a moving standard deviation: I've got a ...
3
votes
1answer
279 views

How to get confidence bands of parameters from a fitting procedure?

I have done fitting of data points with a given model that has two parameters (A and B), using NonlinearModelFit. The result of the fit is the maximum of the ...
4
votes
2answers
3k views

How to use a 3×3 covariance matrix to plot an error ellipsoid?

I have a 3×3 error covariance in Mathematica, but I don't know how to use it for plotting the error ellipsoid. It would be great if you can show me how I can do that for the below covariance matrix: ...
7
votes
1answer
837 views

Wald–Wolfowitz Runs Test

Does Mathematica 8 implement Wald–Wolfowitz runs test for randomness? I can't find it in the documentation. I would like to test some fit residuals.
0
votes
1answer
134 views

No Tukey Test on ANOVA package

I'm trying to use the ANOVA package and have mathematica display the Tukey PostTest, but all I get is this: ...
5
votes
1answer
568 views

Multinomial logistic regression

Has anyone done multinomial logistic regression in Mathematica? The binomial case is essentially done on the LogitModelFit documentation page and works fine. I am ...
2
votes
1answer
162 views

EmpiricalDistribution for Gini Coefficient Runs Slow

I am repurposing code that I found in this blog post (http://datavoreconsulting.com/sports/gini-coefficients-and-the-olympic-medal-race/) to generate the Gini coefficient for other data sets I am ...
2
votes
1answer
174 views

ConditionalEntropy and Statistics`Library`NConditionalEntropy

There is a function available from the Statistics`Library context called NConditionalEntropy that appears to compute ConditionalEntropy. Thus ... ...
5
votes
2answers
606 views

Plotting 2D Data with Categorical Data in One of the Dimensions

I have a 2D data set in the form of: data={{Category, Integer}, {Category, Integer},{Category, Integer}...} It is a pretty simple data set with four categories ...