instruction stringlengths 9 38.7k |
|---|
This is a naive question from someone starting to learn machine learning. I'm reading these days the book "Machine Learning: An algorithmic perspective" from Marsland. I find it useful as an introductory book, but now I would like to go into advanced algorithms, those that are currently giving the best results. I'm mos... |
First, the expected survival time when time is time to event is treated as a continuous r.v. is given as the following:
$$\int_0^{\infty} S(t)\, dt$$
The formula for the mean residual survival time $\text{mrl}(u) = E(T -u | T>u)$ is given by
$$\frac{1}{S(u)}\int_u^{\infty} S(t)\, dt.$$
Can anyone explain the logic of... |
Suppose I have an $N\times N$ covariance matrix that describes a multivariate normal joint distribution.
Now take 100,000 draws of the covariance matrix. I measure the variance of values for each draw -- call this the "cross sectional dispersion". If I average the result of cross-sectional dispersion across draws what... |
I need to explain the concept of linear mixed models in an article targeted at a mainstream audience. Is there a way of communicating the gist of the concept in a sentence or two?
|
i am analyzing a surveillance tool where people could be collected by one or both methods. So it kinda looks like a Venn diagram. What test would I use to test if there's significant differences by the methods for different characteristics? The only statistical package I have access to is SAS so please recommend someth... |
I want to draw vertical line graph (like the first graph on this page):
The deal is I have about ~15k data points whose frequencies (along Y axis) I want to present. I also want to be able to to present the frequencies in different colors : for example for the 1st 5k points, I want yellow colored line graphs for the n... |
I am a bioinformatician and work on RNA-Seq data. The data contains a lot of reads (of length 80 bp in my case). These reads are fragments of those genes that were expressed. I map them back to my reference genome which helps answer many questions (gene expression, snp variants, alternative splicing etc...).
I work on ... |
I'm trying to adapt something like this association football prediction approach to 2v2 foosball games at our office.
For football, they basically have an offense score and a defense score for each time. The game is a fixed length of time. They then use Poisson regression based on the scoring history to try to find out... |
consider a typical ar-garch model:
$y = \sum{b_ix_i} + \epsilon, \epsilon \sim \text{garch}(p,q)$
In such case a typical textbook says that we should first estimate all bi's and then estimate the garch parameters, because regression parameters and garch parameters are independent to each other (asymptotically.)
Althoug... |
I'm looking for a non-technical definition of the lasso and what it is used for.
|
I asked 312 people how many times they visited their preferred local supermarket in a month
The results are as follows:
5% did not visit at all
7% visited once a month
33% visited twice a month
22% visited three times a month
15% visited four times a month
18% visited five and more times a month
In the absence of the... |
Using either truehist() from MASS or just the normal hist() function in R with the prob=TRUE option, I'm getting very strange values for the y-axis. I was under the impression that these values should all be below 1.00, as the relative frequency of any value should be below 1.00 and the area under the curve adds to tha... |
I would like to ask a question about error correction terms from VECM if I may. I am currently working on a lot of time-series data and one of the questions I would like to address is whether there is some relationship between different time-series. Reading around the subject it seemed to me that testing for cointegrat... |
I would like to run KSS test (KAPETANIOS, G. – SHIN, Y. – SNELL, A. 2003: Testing for a UnitRoot in the Nonlinear STAR Framework) , but I don't know how to obtain demeaned data and detrended data. Could you describe me the process in STATA?
|
I have the population which is split into three classes; A, B and C. We know that the number of observations in each class is Na, Nb and Nc respectively. Assuming that my observations are binary distributed how can I specify (with a formula) probability of observing not more than P positive outcomes.
|
I suspect that most users of statistical tools are ancillary users (folks who have had little to no formal training in statistics). It’s very tempting for researchers and other professionals to apply statistical methods to their data simply because they have seen it “done before” in peer-reviewed papers, grey literatu... |
I have an implementation of the Griddy Gibbs sampler, but my observations on which I'm conditioning model parameters are too many in number, thus the likelihood underflows quickly, even with a log transformation.
Sequential updating holds if one is using conjugate priors, since the posterior can be found analytically,... |
In my endeavor to learn forecasting and improve my statistical knowledge, I've decided to forecast the population of a certain area. I've attached the excel file that I used. I know I'm using excel which is not very common around here. I'm familiar with R but prefer excel for fast analysis such as this.
The collected d... |
Suppose I want to see whether $z$ is a confounder for a model with $y$ the outcome variable and $x$ the predictor. If I adjust for $z$, and the adjusted coefficient of $x$ changes versus the unadjusted coefficient of $x$, does it matter by how much it changes? If the difference between the unadjusted and adjusted coeff... |
Hi I am looking for a clear explanation of T statistics concept. Especially in quantitative equity portfolio management context, what does T statistics of information coefficient indicate? How can I tell if it is significant, and if it is, any useful information I could derive from that?
|
I have 2 variables that I want to decorrelate. I was told I can use PCA to do so. I did PCA on the data and got all the parameters. Now how do I get the new set of transformed data that no longer correlates with the second variable? I want to use this set for further analysis.
thanks,
|
I am looking to model some data, but I am not sure what type of model I can use. I have count data, and I want a model that will give parametric estimates of both the mean and the variance of the data. That is, I have various predictive factors and I want to determine if any of them influence the variance (not just t... |
I have a 1D data set with 83163 data points, and I would like to know whether the data follows a normal distribution.
I tried using shapiro.test and ks.test in R:
d is a vector containing the data
shapiro.test(sample(d, 5000))
Shapiro-Wilk normality test
data: sample(d, 5000)
W = 0.9694, p-value < 2.2e-16
(Re... |
I want to plot interaction between two variables in SAS. One is continuous and the other is binary.
|
In my research I have run into the following general problem: I have two distributions $P$ and $Q$ over the same domain, and a large (but finite) number of samples from those distributions. Samples are independently and identically distributed from one of these two distributions (though the distributions may be relate... |
This is actually part of a problem from All of Statistics:
$X_1, X_2, \ldots, X_n \sim \text{Uniform}(0, \Theta)$. And $Y = \text{Max}\{X_1,\ldots, X_n\}$.
If you're given that $Y > c$, can you estimate the probability of $\Theta>1/2$?
Of course if $c\ge1/2$ the probability is 100%.
Any hint or direction is appreciate... |
I am trying to move data analysis from proc mixed to glimmix for the easy of the ilink transformation. However I am finding a big difference on the denominator DF when using either of them. As background. My data comes from a group of 95 calves that were fed 4 diets (about 24 calves per diet), my measure is neutrophil ... |
I need some advice on explaining $\chi^2$ as a contingency measure from a pedagogical perspective.
I usually introduce the individual terms in the $\chi^2$ sum as scaled deviations from independence; my argument claims that $d_{ij} = (n_{ij} - E_{ij})^2$ is an absolute measure but we want relative measures that are ind... |
I thought that the canonical link function $g(\cdot)$ comes from the natural parameter of exponential family. Say, consider the family
$$
f(y,\theta,\psi)=\exp\left\{\frac{y\theta-b(\theta)}{a(\psi)}-c(y,\psi)\right\}
$$
then $\theta=\theta(\mu)$ is the canonical link function. Take Bernoulli distribution as an examp... |
I simulated a time series using expressions (3.10a), (3.10b) from (Hyndman et al., 2008). Next, I'd like to use a simple exponential smoothing method to forecast for the next period.
For a given initial point $\hat{y}_1$ I obtained the smoothing parameter $0<\alpha<2$, etc.
My question is as follows: am I going to pre... |
I have a random field, F, defined on the surface of a sphere pixellized into about a million points. I know that F must consist of two components - F1 and F2, F1 being a true signal and F2 being some contaminant. They cannot be measured independently but it is known that they should be completely uncorrelated to each o... |
A probably very basic question about multi-factorial ANOVA. Assume a two-way design where we test both main effects A, B, and the interaction A:B. When testing the main effect for A with type I SS, the effect SS is calculated as the difference $RSS(1) - RSS(A)$, where $RSS(1)$ is the residual error sum of squares for t... |
At the following figure at left side two realizations of point processes with different density (intensity) $\lambda_1$ and $\lambda_2$ is being mixed matching the center of the belonging areas to build a point process in the middle with intensity $\lambda$. Then randomly selected points as two sets extracted from it a... |
I have a small table like this
Outcome Feature_1_Value Feature_2_Value Feature_3_Value .....
1 1 1.2 3.7
9.7 2.3 3.976 4.65
.... .... .... ....
There is an outcome that depends on what values... |
I have data from a biological experiment of the following form:
site1 site2 site3 site4
Condition A | replicate1 | 0.30 | 0.15 | 0.50 | 0.05
Condition A | replicate2 | 0.27 | 0.18 | 0.48 | 0.07
Condition B | replicate1 | 0.50 | 0.15 | 0.30 | 0.05
Condition B | replicate2 | ... |
I need to know the types of tests I need to be thinking about for this stats project. I will then go and look up the specific tests you recommend. The data is from all 50 states for the years 1960-2010.
I think the best way to illustrate the data is to show an example (I just made up numbers):
State Conditio... |
I'm running a GEE on 3-level unbalanced data, using a logit link. How does this differ (in terms of the conclusions I can draw and the meaning of the coefficients) from a GLM with mixed effects (GLMM) and logit link?
More detail: The observations are single bernoulli trials. They are grouped clustered into classrooms ... |
I am given an exercise, and I can't quite figure it out.
The Prisoner Paradox Three prisoners in solitary confinement,
A, B and C, have been sentenced to death on the same day but, because
there is a national holiday, the governor decides that one will be
granted a pardon. The prisoners are informed of this but ... |
Here is the article that motivated this question: Does impatience make us fat?
I liked this article, and it nicely demonstrates the concept of “controlling for other variables” (IQ, career, income, age, etc) in order to best isolate the true relationship between just the 2 variables in question.
Can you explain to me... |
I wish to run some simulations on the 'estimates' of an event provided by experts (or historical data if available).
For example: The technology manager of company X says that probably 300-1000 computers in the organization (out of say 100,000 in total) have Windows XP that needs to be phased out.
Now this is an estim... |
I am using JMP to examine differences in vegetation cover in growth form groups (trees, shrubs, forbs, etc.) before and after three treatments with a control.
My sample size is small (n=5) and most of my distributions are not normally distributed.
For the normal distributions I used ANOVA to analyze the differences (pe... |
I know how to do factor and canonical correlation analysis on raw data in R. But sometimes we only having correlation matrices for the data. I'd like to know any R functions which can take correlation matrices as input for factor and canonical correlation analysis. It is easy to write dedicated functions but it is nice... |
I don't really understand the difference between exponential and geometric distribution.
|
I asked people how many times they visited their local pub in a 'normal' week.
The result can be zero, one, two, three, four, and five and more.
The mean is 2 and the standard deviation is 1.3.
So two standard deviations above the mean is 4.6.
However, two standard deviation below the mean is -0.6.
Is this negativ... |
I am using a generalized linear model to analyse my data, there are 6 explanatory variables. I have added all different variable combinations in different models, and ranked them according to their AIC weights. Only one variable is really significant in any of the models, but different models with different combination... |
I have data for two groups. The 2 groups are matched on a number of variables, but differ in the scores on an alcohol measure (one group is high, and one is low). However the groups have been created so that they capture the extremes of the alcohol measure (all very low in one group, all very high in another) therefore... |
Following the post here, I am wondering if reporting the mean and standard deviation is appropriate when describing a composite score.
My composite score is the total of responses on several likert scale items and count variables.
I have made sure that all are on a five point scale, based on their level of importance,... |
I have a continuous response variable, nominal independent, and want to block by site, though the numbers at sites are unequal. Is there any alternative to a permutation test? If not, does anyone know of an automated process for designing a permutation test for a rookie like me?
Thanks very much
|
Conditioning a point process is the concept being investigated in this post. The marked point processes are of interest.
Figure A demonstrates a phenomenon being investigated for modelling. We recognize a feature such can be modeled by a point as the center and an angle (Figures B and C). Therefore we construct a point... |
You probably know the trick in the movie The Prestige :
[MOVIE SPOILER] A magician has found an impressive magic trick: he goes into a machine, close the door, and then disappears and reappears in the other side of the room. But the machine is not perfect : instead of just teleporting him, it duplicates him. The magici... |
I was wondering, is it possible to have a very strong correlation coefficient (say .9 or higher), with a high p value (say .25 or higher)?
Here's an example of a low correlation coefficient, with a high p value:
set.seed(10)
y <- rnorm(100)
x <- rnorm(100)+.1*y
cor.test(x,y)
cor = 0.03908927, p=0.6994
High correlation... |
I'm curious if there are any analytical or empirical methods to estimate the time it would take to process a data set (grouping or various prediction algorithms). Known variables would obviously include the size of the dataset, but also the types of variables (continuous/discrete), the number of factors for discrete v... |
I have devised an algorithm that takes as input a dataset $s$ and two parameters, $k$ and $d$. $k$ is discrete while $d$ is categorical. My algorithm outputs a vector $v$ of length 20 which contains real numbers between 0 an 1.
I run my algorithm on three different datasets $s_1$, $s_2$, $s_3$. For each dataset, I vary... |
Is a "split plot" ANOVA with two factors identical to two-way ANOVA with repeated measures in one factor? if not, what is the distinction?
|
In the general case, if I have a symmetric, invertible (real-valued) matrix where each entry in the matrix has a separate error associated with it (or, in the more general case, where each value has a separate positive and negative error associated with it), how can I rigorously propagate these error values through the... |
I have the following data and am really unsure how to analyse it. The actual scenario would take too long to explain so this is an analogous example:
Two groups of participants (n = 8) are asked to roll a die 60 times (each participant rolls 60 times) and record how many of each number they roll. The relative proportio... |
How would you go about explaining i.i.d (independent and identically distributed) to non-technical people?
|
I have a question about the following problem: estimate $\mu=\mu_1,...\mu_n$ when $Y_i \sim N(\mu_i,\sigma^2)$ using a ridge like penalty
$$
\min_\mu \sum_i(Y_i-\mu_i)^2 + \lambda\sum_i\mu_i^2
$$
I have calculated the closed form decomposition of the generalized cross validation error and I know the optimal $\lambda... |
I was reading a couple of the write ups from a Kaggle challenge: Here is one and another
and it got me wondering about variable creation in data mining and why there seems to exist so few texts or case studies available.
Are there any example out there besides Dorian Pyle book?
I am thinking full case studies of predic... |
In other words, based on the following, what is p?
In order to make this a math problem rather than anthropology or social science, and to simplify the problem, assume that mates are selected with equal probability across the population, except that siblings and first cousins never mate, and mates are always selected f... |
A researcher collected some data of a response/outcome variable Y from, for example, 20 subjects. In addition to an explanatory (within-subject or repeated-measures) variable A (a factor with two levels, A1 and A2), he would also want to consider another explanatory (and continuous) variable X. He's interested in findi... |
Problem: I have a "classifier" that uses some arbitrary hypothesis test on observations from one of two known probability distributions:
$P_0$ (null hypothesis $H_0$) is a zero-mean Gaussian $\mathcal{N}(0,\sigma_0^2)$
$P_1$ (alternate hypothesis $H_1$) is a mixture of the zero-mean Gaussian from $P_0$ and some other ... |
Firstly, I suppose that not all active members of this interesting site are statisticians as their job. Otherwise the question being asked as follows does not make any sense! I respect them of course, but I need an explanation that is a bit more practical rather than conceptual.
I start with an example from Wikipedia... |
I have the classifier accuracy output in percentage and the number of input samples. Is there any test that can tell how statistically significant is the result based on this information.
Thanks
|
This question illustrates the difficulty of a person mastering statistics and probability on their own, in the face of weakly developed resources like Wikipedia.
It occurred to me that consulting statisticians, and there are a few here, may routinely face the challenge of explaining certain concepts and methods to a cl... |
Suppose $X_1, ..., X_n$ are $d$-ary discrete random variables which are part of a Bayes network, in which $X_i$ has $n_i$ parents. What is the number of parameters for the Bayes network?
|
What are the modeling approaches depicted here? Can you name them and their prominent proponents or a landmark model? Is there an accepted superior approach? Who prefers which approach?
(From: http://www.stat.duke.edu/~mw/fineart.html)
|
Say we have TWO tests for cancer. Each test has the same probabilities of being right/wrong for cancer/no cancer. What is the probability of getting two positive test results?
In what follows, I'll use C for "has cancer", "+" for a positive test result, "++" for two positives (I don't distinguish between the tests beca... |
There is a fairly common theorem, which states that:
The sum of $n$ independent variables following an exponential distribution $\mathrm{Exp}(\alpha)$ follow an gamma distribution $\mathrm{Gamma} (n, 1/\alpha)$ (also known as Erlang distribution).
I'm using this theorem in my thesis. I've been asked to cite the paper ... |
Could anyone elaborate on a theoretical perspective of K-fold cross-validation and especially a mathematical formula for k-fold CV prediction error?
Updated:Could any one of you help me to understand the formula written on latest edition (Feb, 2011) of the book at page 242.
|
Is there any open source library or code which implements Logistic Regression using L-BFGS solver?
I would prefer Python, but other languages are welcome, too.
|
Suppose $S$ is distributed as a Wishart matrix with $n$ degrees of freedom and scale matrix $\Sigma$, and let $\vec{a}$ be a fixed vector. It is well known that $\vec{a}^{\top}S\vec{a}$ is equal to
$\vec{a}^{\top}\Sigma\vec{a}$ times a Chi-square random variable with $n$ degrees of freedom.
I am curious about the dist... |
I have a process with 15 effective variables. I could record 9 variables to study its effect on process.
I am looking for an appropriate factor to estimate the value of effectiveness of each factor. I believe p-values, standardized coefficients, partial correlation and partial $R^2$ are the potential solutions in this ... |
I am trying to analyse (using R) a set of r(theta) data to see if the magnitude (r) is dependent on direction (theta). I have looked at circular statistics but these only seem to deal with the distribution of the observations theta(i) around the circle.
Our null hypothesis is r=1 for all theta, vs its not.
If H0 is ... |
Is there a unit root test that works with structural change? I only found Zivot-Andrew test but I would try another test, I do not know if the timeseries has a structural change, so I need a test that works with A break at unknown time.
|
N.B., The questions require a bit of setup, which I've tried to present abstractly; please feel free to comment on anything that needs clarification.
I have problem where I am predicting the value of several actions for an ensemble of systems that satisfy a particular set of constraints, then observing the each of acti... |
I am pretty new to statistical testing with confounding variables, so please excuse if there will be some gross misunderstandings or basic questions.
I want to test for systematic differences in species abundance ($y$) between several types of environments ($x$). The way I would usually approach is with a Kruskal-Wall... |
How do you report Kruskal Wallis One Way Anova and post hoc results according to APA (American Psychological Association) 6th ed. standards? I have tried to find a template for reporting the results for the Kruskal-Wallis one way analysis of variance test and post hoc tests. I have found a number of descriptions but ... |
How do I approximate the following integral using MC simulation?
$$
\int_{-1}^{1} \int_{-1}^{1} |x-y| \,\mathrm{d}x \,\mathrm{d}y
$$
Thanks!
Edit (Some context): I am trying to learn how to use simulation to approximate integrals, and am getting some practice done when I ran into some difficulties.
Edit 2+3: Somehow ... |
I'm a hobbyist programmer whose friend recently took a business trip overseas. He's polled our mutual friends for bets on the size of his email inbox when he returns. I'd like to visualize this as a one-dimensional heatmap where color reflects a kind of density of guesses for that value. I understand I could create ... |
I'm studying a data set in R using both regression trees (tree and rpart functions) and logistic regression. I'm finding explanatory variables in the regression which are significant, but when I fit a tree those variables are not used as splits. What does this imply about the predictive ability of the results?
|
Let's say I am analyzing behavioral patterns over the course of an hour. I have recorded three different behaviors and the time stamps (start end) they occurred at. Something like:
yawning stretching whispering
2:21-2:22 3:31-3:33 1:21-1:30
3:42-3:45 8:23-8:59 9:27-9:33
9:20-925 9:34-9:4... |
I have what I'm afraid is a simple stats problem that is stumping me. I have two random variables, X and Y, independently normally distributed:
X ~ N(0, sigmaX)
Y ~ N(0, sigmaY).
I observe the sum of these two variables, Z = X+Y, and want to develop a conditional expectation on X given the sum. A colleague said, "ah... |
Following on from my post here, I have three statistically significant correlations between Variables A and B for three age groups. They are:
Group 1 (Less than 18 years) r1 = .74 p < .001 n = 99
Group 2 (18 to 65 years) r2 = .78 p < .001 n = 96
Group 3 (More than 65 years) r3 = .75 p < .001 n = 97
Note: I have done ... |
In text classification and clustering, the number of features are normally big, e.g. I currently get are around 5,000 features which is already really small compared to many other text mining tasks. Given I am totally new to visualization, I have no clue about how should I plot the results from text classification and ... |
I am transforming an unscaled density function to log scale to avoid underflow issues.
BI was performing integration on this function on a grid of values before I used the log transormation, to build a grid based cumulative distribution function. Then, using a draw from uniform[0,1], I was choosing the the largest poi... |
I am a bit new to this field. So I needed help in finding out which topic should I focus on for achieving this.
Suppose I have N dependent random variables. I have n samples of each of these random variables.
Now I want to check if the kth sample follows the pattern that is suggested by the previous (k-1) samples.
For ... |
I've created a few Cox regression models and I would like to see how well these models perform and I thought that perhaps a ROC-curve or a c-statistic might be useful similar to this articles use:
J. N. Armitage och J. H. van der Meulen, ”Identifying co‐morbidity in surgical patients using administrative data with the ... |
Let A, B, C, and D be four random variables such that A and B are independent, and C and D are dependent. It is unknown whether A and C are independent nor whether B and D are independent. Let E and F represent the products E = AC and F = BD. Are E and F necessarily independent?
If not, say we add the knowledge that A ... |
I have a population that I measure a value from once a day. I then made a change, and continued to measure that same value from the same population.
What test could I use to prove that my change did not affect the mean of that value? I'm not sure if the normal difference between two means tests that I know would apply... |
I have not used my stats in a while and was interested in how the group would handle the following:
I have a multi-year insect data set that has irregularities in trapping effort, trap type and area of trap size within a specific trap type. I am interested in obtaining measures of relative abundance, dominant species, ... |
I am using the Kolmogorov–Smirnov two-sample test to compare distributions, and I noticed a $p$-value is frequently reported as the test statistic. How is this $p$-value determined? I know it's the probability of obtaining a result at least as large as the one obtained, but how is this $p$-value determined given this i... |
For a classification project we are using the randomForest package in R, which wraps the Breiman Fortran random forest implementation, to assess the importance of each of our features. I would like to calculate p-values for each feature's importance statistics as described in the random forest documentation provided by... |
Disclaimer:
this is directly related to a homework problem. The example I am giving is based off the homework problem (because I am more interested in how to solve it than in what the answer is).
Data given:
Number of people surveyed: 50
Sum of x values: 1500
Sum of y values: 500
Point on least squares regression line... |
I have two data sets, A and B. Both have a large number of continuous variables. I believe that A is related to B. But there are no defined classes in either A or B. I could do a bunch of correlation tests to see if any of the variables in A are strongly correlated with B. But many variables in A are likely dependent o... |
I am measuring for the existence of response in cell signal measurements. What I did was first apply a smoothing algorithm (Hanning) to the time series of data, then detect peaks. What I get is this:
If I wanted to make the detection of the response a bit more objective than "yeah you see a raise in the continuous dro... |
The following is my experience doing some researches linked to statistical concepts. In the most situations I had no idea on how to organize the questions, how to ask for answers, and how to provide feedback showing my acceptance or rejection. I'm certainly not talking about the language issue but pointing on that it w... |
I am doing a discriminant function analysis and I have four continous independent variables
and one categorical dependent variable (that has 3 groups). I have
chosen to do this analysis to see how these groups
can be predicted by the four independent variables.
Firstly, when we are interpreting the results, do we loo... |
Consider an integer random walk starting at 0 with the following conditions:
The first step is plus or minus 1, with equal probability.
Every future step is: 60% likely to be in the same direction as
the previous step, 40% likely to be in the opposite direction
What sort of distribution does this yield?
I know t... |
Consider a set of DNA sequences i.e. strings composed from the four
letters A, C, G, T.
We model these sequences as a random vector, $\mathbf{X}=(X_1,\dots,
X_n)$. Each member of the set of sequences is a realization of this
random vector.
In this case the $X_i$ only take the values A, C, G, T. More generally
let $r$ ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.