# Tagged Questions

Questions on the statistical functions of Mathematica.

1answer
219 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 ...
3answers
688 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 ...
1answer
191 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. ...
1answer
690 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 ...
1answer
227 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 ...
1answer
1k 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 ...
4answers
231 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 ...
1answer
449 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 ...
1answer
134 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 ...
1answer
143 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. ...
3answers
549 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 ...
1answer
342 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 ...
2answers
435 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 ...
0answers
1k 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 ...
1answer
163 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: ...
1answer
356 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 ...
0answers
47 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. ...
0answers
139 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, ...
1answer
405 views

### Unexpected behavior of confidence bands for data presenting two regions with uneven noise

Let's generate some noisy data with uneven noise. ...
2answers
825 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 ...
0answers
184 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. ...
0answers
762 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 ...
1answer
527 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 ...
0answers
69 views

### Changing GeometricBrownianMotionProcess function

Since the function GeometricBrownianMotionProcess is given by Mathematica I have some technical questions. If we consider the following example: ...
3answers
564 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 ...
0answers
503 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) ...
2answers
194 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 ...
2answers
587 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 ...
1answer
632 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.
3answers
3k 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 ...
1answer
209 views

### CorrelationTest small bug?

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

1answer
255 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 ...
1answer
153 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 ...
1answer
473 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 ...
2answers
4k 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: ...
1answer
990 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.
1answer
163 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: ...
1answer
832 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 ...
1answer
198 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 ...
1answer
240 views

### ConditionalEntropy and StatisticsLibraryNConditionalEntropy

There is a function available from the StatisticsLibrary context called NConditionalEntropy that appears to compute ConditionalEntropy. Thus ... ...
2answers
1k 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 ...
4answers
3k views

### Function for Autocorrelation

Is there a built in function to compute the autocorrelation of a signal ?
1answer
276 views

### Obtaining standardised regression coeffiecients

Regression coefficients are the constant that indicate the rate of change in one variable as a function of change in another. Standardised regression coefficients are the same, but refer to a change ...