tttjjj/elt_bench huggingface dataset:
Conceptually, a one sided test is really a test in the form $H_0: \\theta \\le 0$ vs. $H_A: \\theta \\gt 0$ rather than  $H_0: \\theta = 0$ vs. $H_A: \\theta \\gt 0$.  In elementary expositions, especially those seen on the Web, this distinction is glossed over, but it is carefully and correctly handled in the statistical literature and good textbooks.  Thus we are *not* restricting the parameter space.
You might also be interested in the recent paper: R. Beran (2010), [The unbearable transparency of Stein estimation](http://projecteuclid.org/euclid.imsc/1291044739), *IMS Collections*, vol. 7, 25-34. Of course, you'll have to forgive the author somewhat for the choice of title, though the selection was intended, I believe, to make a point.
In order to help you, we would need to know how the first (which shows what hypothesis you are interested in) and second (which shows what tool you used to collect data) paragraph are connected. Do you perhaps have an external variable that says whether respondents belong to stakeholders or middle managers class, or do all items target the same kind of respondents (unrelated to the above distinction)? Does it make sense to use all items (i.e., do they refer to the same unidimensional construct)? etc.
$z$-values are in the margins.
Probabilities are within the table.
To remember this, note that the margins contain values that are negative or larger than one; therefore they cannot be probabilities.
Of note: http://stats.stackexchange.com/questions/27662/what-are-the-major-philosophical-methodological-and-terminological-differences
In my post "probability function" is synonymous with "probability mass function", though the term is sometimes applied to continuous random variables to refer to their density function (see [here](http://mathworld.wolfram.com/ProbabilityFunction.html) for example). The word "sample" applies to both, since you're dealing with a sample.
I would say yes.  The spike at zero won't matter much.  What matters is not so much whether your original distribution is normal, but rather that the average of $M$ samples from this distribution will be normal enough to use the standard confidence interval.  If $\\hat\\mu$ is above $0.05$ and $M=10,000$, then I would say you are OK.
good question. personally i have been thinking about these stuff. but don't have a good answer.
For starters: P(you have the disease|test is positive) != P(test is positive|you have the disease).
Thanks for the introduction to `type='h'` for generating verticle line (e.g. needle plots). However, Manhattan, as Harvey indicated, is the term for multiple testing and p-value context specifically.
Great, that's what looked most natural to me. Thanks!
Thanks for the response. I'll investigate a little further. I hope your answer is correct so I don't have to purchase any more stats packages!
I meant the answer that you called "the provided answer" in your own question. I simply repeated your phrase.
Because you appear to contradict yourself concerning K-means, let's clarify the point here: the variance in any K-means problem is a positive-definite quadratic form and thereby defines a valid distance (which can be considered Euclidean: this property is essential to efficient implementations of the algorithm). Thus K-means actually *is* using a fairly restricted form of distance.
I should note that if your partitions are highly sensitive to the initial points selection, it means your data do not have natural clusters and a $k$-means clustering algorithm might not be the best thing to use. Or, you are trying to fit more clusters than the data naturally present.
Follow-up question is here: http://stats.stackexchange.com/q/50308/930.
@MattReichenbach No problem, although they do offer a 90 day free trial of pretty much the full version of their software.  The only limitation that I found is when doing CCR, you can't analyze more than 20 columns at a time.

Regardless though, if you have some data and you can put it in speadsheet form for me, I'll run a CCR on it and give you the results back.  Just open a chat with me.

And no, I don't work for XLSTAT or have any affiliation with them at all as it probably seems from my posts.
One must be cautious with those links, though. A multinomial is a distribution in $\\mathbb R^n$ and the components are dependent, so the standard basic theory of order statistics doesn't strictly apply. An additional subtlety is than the particular multinomial distribution of interest here is *exchangeable*. This provides some useful additional structure.
@QuantIbex: done.
@cardinal flag does not support quant.stackexchange (prob bc it is still beta).  Mind migrating it?  Thanks,
19. The Postal Service is attempting to reduce the number of complaints made by the public against its workers.  In order to facilitate this task, a staff analyst for the Service regresses the number of complaints lodged against an employee last year (Y) on the hourly wage of the employee for the year (X).  She obtains the following results:
	Y = 10.2 - 1.6X + e
	r2 = .73 Syx = 1.1  sb = .87   n = 348
Yes, I know of mixed effects models, but I wanted to try the old method for fun.
Thanks to you Glen and @whuber for the valuable discussion on this question. I must say that both of your posts comments and discussion served as an eye opener to me and simplified numerous statistical facts that were previously hard to understand (for me).
Great answer. Thanks @cbleites.
Sure, in fact that's what was being discussed and the reason why one shall use another dispersion measure.
For the question and the answer to be on topic here, they need to be expressed in a way that is understandable to non-`R` users.  Mathematical notation and/or English descriptions would be good choices.
I know this already, that the information flow is blocked at C where we have a "V-Structure". What I want to know is why; why a V-Structure blocks the information flow when we do not observe C, from a cause-effect relationship point of view.
This depends entirely on what features you intend to use.
Maybe more suited for http://stats.stackexchange.com/
`California and North Carolina...` California and Arizona, you mean, Peter? [BTW I sometimes night-dream like visiting Arizona.]
Also [posted on math.SE](http://math.stackexchange.com/q/138623/15941) by a different user.
this should be community wiki.
Michael, @whuber has given an exploratory approach to discovering this; here is some intuition. The sums are mixtures of binomials. Consider a clustering-like scenario: A mixture of two bivariate normals, each with $\\rho = 0$ (hence having independent coordinates). Suppose the mean of each coordinate is zero in the first mixture component and is 10 in the second mixture component. If I tell you that $X = 9$, then you certainly wouldn't claim that this tells you nothing about the value of $Y$. Right?
My apologies for nitpicking, but your first sentence is mis-worded. $\\beta$ is the probability that the null hypothesis will not be rejected *given that it is false*.
Dikran, though GA make natural selection but does not ignore the information as you mentioned, it only ensure if the selected solution solve its problem if not, it find out to know why and upgrade the agorithm which form the basis of it dynamism till the network converge at one or two best solution. hope you get that rignt?
Greg - You are indeed correct and I owe you many thanks. I've just run the updated code and the intercept values came out to be the same.
(+1) It is ideal to have more than one way to prove everything. Maybe someone will post an answer considering the transformation $(X,Y)\\mapsto(U,V)=(X+Y,X)$.
@rolando2, I probably don't have the patience for that and in this case need to go with something simple. Out of curiosity though, could you describe or provide a link that has a basic description of generalizability theory?
This is more a question for better understanding your question (though I know you've figured out the answer). Can you please help me understand how you arrived at this: - "The AR(2) process y t =ϕ 1 y t−1 +ϕ 2 y t−2 +ϵ t has the general linear process form ψ(u)=1/(1−ϕ 1 u−ϕ 2 u 2 ) and hence.." I'm not able to understand how you arrived at a general linear process form. Pardon my ignorance!
In the absence of a clear probability model--which is not in evidence at this time because the nature of the data collection method has not (yet) been disclosed--it is not possible to tell whether this advice will produce good or bad results.
If some of the terms in your model cannot be estimated, how _would_ you compare it with models that can be estimated? You should not even be able to calculate the AIC without having the MLE for all your parameters.
"Variance" is a function of one variable, so I'm not clear what you mean by "variance of a cluster". You could find various measures of the distance between points, calculated in various ways. Is that what you had in mind?
What are you trying to find out?  Quite likely you don't need chi-square at all.
A somewhat related question was asked here, [Logistic Regression: Which pseudo R-squared measure is the one to report (Cox & Snell or Nagelkerke)?](http://stats.stackexchange.com/questions/3559/logistic-regression-which-pseudo-r-squared-measure-is-the-one-to-report-cox-s).
@Glen_b thanks for pointing this out. Relatively small inaccuracies would be tolerated by our Customer since one definition of Engineering is "the art of approximation".
Could you please elaborate? What do you mean by k-means results are crappy? (worse than other clustering techniques, not informative, and for what uses?) Thanks!
There are thousands of scientific papers that use nothing more than ANOVA and t-tests. Some of them even correctly.
check this [page](http://en.wikipedia.org/wiki/Multiple_correlation)
The normal is not conjugate, but it is conditionally conjugate if you introduce a latent Gaussian $Z$ Such that $Z > 0$ corresponds to a success. To use this idea for Bayesian inference, one then runs a Gibbs sampler.
+1 Good answer.  It's worth pointing out the drawbacks of simulation.  (The alternative is that power curves can be computed mathematically.)  Simulation becomes unwieldy when many parameters (such as effect size and sample size) have to be manipulated or when you are seeking some threshold value, such as a minimum sample size.  Even an *approximate* exact expression for the power can be valuable for indicating in general how the power behaves and for identifying initial solutions that can be polished with a little bit of simulation.
I don't understand this sentence: "2.why some of data sets are hard? such as wine." Could you please clarify it? Thx.
I presume you mean, "lambda?" Anyways, this isn't appropriate for MO.
@MichaelChernick Point taken. I didn't mean to imply that *all of Bayesian statistics and philosophy* has close frequentist analogues and vice-versa, only that one can often find a *method* that will accomplish the same job from either camp, and that the Bayesian approach tends to be the more flexible of the two. Perhaps I should have emphasized that, even when the parameter estimates you get from the two schools are identical, they should still be interpreted differently, as Procrastinator pointed out elsewhere.
What is an "e-value"?  This is not a standard term AFAIK.  Could you supply a reference?
@Henry: The OP may be referring to just the terminology.  As for how I *might* refer to such an event, I would have to invoke Douglas Adams' Infinite Improbability Drive.  Or call it a White Queen phenomenon, as she could believe 6 impossible things before breakfast.  :)
Done. Looks like sourceforge rearranged
I don't know of any literature talking about this issue, but have you thought about first identifying the location of the structural break, say at time $i$, then "difference" it out of all periods $j > t+i$, and then run your unit root tests? This would be somewhat analogous to adjusting for seasonality before employing further diagnostics.
When $\\lambda$ is close to 0, a log-transformation is usually a better choice, because it is more interpretable.
Whether this is appropriate depends on what you already know or assume about your data generating process. Subsampling the data by region (i.e. take all points in some predefined smaller window) can be dangerous if it's not homogeneous (because using a different window would have changed your conclusions). Sampling the data without regard to positioning for a training set has the effect of "thinning out" the observed process and invalidates conclusions you might want to draw about e.g. the range of correlations between marks or clustering/repulsion processes.
A bit of both, probably more the first one.  I found that using different RF's on different chunks of data increases the overall AUC.  I'm basically looking for a more efficient way of finding which chunks of data to carve off for their own RF.
It is a [Monte Carlo](http://en.wikipedia.org/wiki/Monte_Carlo_method) simulation
When presented with a categorical variable, the GLM does pairwise comparisons against some base reference level to all the other levels. So if you have 5 levels in your categorical variable, the glm would compare lvl 1 and 2, lvl 1 and 3.. and so on. As to what levels are significant, there's a post [here][1] that may help.


  [1]: http://stats.stackexchange.com/questions/31690/how-to-test-the-statistical-significance-for-categorical-variable-in-linear-regr
I think we need a bit more information. What are you comparing? What sort of data do you have? Is it a single outcome you a measuring per centre?
I think your first four paragraphs are a bit of a red herring--there are frequentist approaches to interim monitoring. It's true that (Bayesian) posterior updating lends itself nicely to this, but you could frame this problem in many different ways.

Thanks for the pointer to the slides!
Try v2.........
Does this package estimate the number of change points as well? In an editorial of RNews of 2008 (www.r-project.org/doc/Rnews/Rnews_2008-1.pdf) the author states: "The package is not concerned with estimation of the number of the breakpoints.". Has this changed in the meantime? In the editorial they refer to methods like AIC, BIC as Maciek mentioned.
$z_n$ follows a $Multinomial(\\theta)$ where $\\theta$ is the (also latent) topic proportion for the document. $w_n$ is also multinomial, given $z_n$ and $\\beta$.
@gung: You're right I double counted the intercept.  I'll fix it.
Just a comment to emphasize that, for any of these methods, you need to know the total number of p values and the author said he/she does not know that
@Frank Thanks. Corrected now.
Dear @COOLSerdash, thank you for your reply.
What's your intended analysis using this data? The practice of removing outliers is of dubious statistical credibility: you can "make data" to give significance or lack of significance at any level by doing that. Are populations A and B which received measurements using methods A and B truly homogenous populations or is it possible that your methods have just given you different populations?
@PLV, i'm afraid you need the fixed or random effect around the error variance between groups, if you observe different dispersions between groups.
@prob - I appreciate your giving it a shot.  I'm still unable to follow.
Darn. Googling the syntax just now turned up BUGS code for a VAR model [here](http://www.wiley.com/legacy/wileychi/raymer/supp/Chapter12_appendix.pdf); it's purported to work :) maybe a clue in there...
You don't invert a matrix with `^-1` in R, and in fact shouldn't explicitly invert $X^TX$ at all. (Also you don't do matrix multiplication with `*`). You should solve $(X^TX)\\hat\\beta = (X^TY)$. See `?solve`, which does both solution of linear systems and inversion. That's still not the best function to use if you're trying to be accurate (QR decomposition is probably the most common way these days), but it will do for getting the ideas down.
$M$ in the first equation can be a neural network with the best structure for the given data.
$M_1$ is a biased model (for example, a non-optimal neural network for the given data) and $M_2$ models the remaining information not modeled by $M_1$.
@ttnphns added very brief discussion with links, in the hopes that the OP will either clarify or ask a followup.
Could you add what kind of "answers" do the tests provide? Do they give a yes/no, a stage out of some number of stages, or a score? And do they produce different scales? For instance, does the clinical one give a score, but the hystopathological one give a yes/no?
(+1): writing out the model formula for each model is indeed the best way to make R-notations more transparent; good job!
Would it make sense to combine the variables? Eg, [BMI](http://en.wikipedia.org/wiki/Body_mass_index) is composed of both the length (ie height) & weight of a person.
If I am understanding this correctly we use the cross validation to ascertain the number of features that go into the random forest model as opposed to the number of features that the model will try at every step. Correct ?
what do you mean by "recurrent" features?
+1 for the J example.
Do you need to multiply b by 100 to get the elasticity? If b=2, is that saying that for a 1% increase in x you get a 2% increase in y?
Thank you very much for your extremely descriptive answer.
Can you add the data to your question? In R this can be easily done with the dput() command.
The "sufficient" sample size should be a trade-off between above-mentioned facts and also sampling costs (time and money). Thus I would go for n =/> 50 in ladislav's example.
Actually, I was thinking for sem package. Are you suggesting lavaan instead? Further, is there any bibliographic reference or other recommendation for this procedure to cite in an article?
*Don't* treat the data as truncated but as right-censored, with likelihood $[1-P(t_{\\mathrm{max}})]^{n-k}\\prod_{i=1}^k p(t_i)$, where $P(\\cdot)$ is the cumulative distribution function.
One thing it does do is largely remove a lot of alternative explanations.
This sounds like a homework/self-study problem. Please add the self-study tag and your thoughts on the problem. See http://stats.stackexchange.com/tags/self-study/info.
Welcome to the site, @Luis Gonzaga Sarmiento. I tried to edit this to make the English smoother, but I was not sure what you meant in each case. Please ensure it still says what you want it to. In addition, can you clarify the phrase "is meaning the trend remains"? This seems like a fragment to me. Lastly, notice that your username, your identicon, & a link to your userpage is automatically added to your posts, so there is no need to sign your posts, & in fact, we prefer if you do not.
It would be good to spell out GAM and GAMM; not all readers are fluent in English, and acronyms can be troublesome.
I'm not quite clear on what your data look like.  How does a "query" (in your last paragraph) relate to a "sentence" in the rest of the question?  But I've answered it on the basis of what I think you are asking.
In R the `ordinal` package handles ordinal data well and can do multi-level models. It also comes with nice vignettes and tutorials.
Note the cauchy distribution have infinite mean too, so that is the reason why it performs poorly.
you could keep bookmarks of your hidden layers. im having with boltzmann machines in general, but that should work.
+1 I usually add the `scale()` option too, but when I want to express days as years, I use `scale(365.24)`. This is because there are 24 leap years per century. (I know this is probably just a trivial detail, and `365.25` is very often used.)
@ Nick Cox: I think that's a fair suggestion, so I moved the "new" criterion down and deemed it as optional.
At this point, I'm afraid I'm not sure if this is not purely an R issue: there's a formula interface which allows to select all predictors and their interactions, e.g., `y ~ .^2` will consider all variables and their first-order interaction. It then depends on what model you want to use to perform feature selection. Formulae are not always efficient in R, but loops aren't either. If your question is specifically about feature selection with such irregular data set, please clarify. Otherwise, it will be migrated to Stack Overflow (no need to cross-post).
No, what was on the axes definitely does matter.  Based on what you've written, I can imagine two different plots: one that is illustrating change in the variability of Y as X increases (in which case a simple line might be valid), and one that's illustrating the actual relationship of X and Y, which might include the mean and and SD lines... or might not.  Why 1 SD?  Why not 2?  We can only give plotting advice with some kind of context.  If people will be plotting whatever they want, all you can do is make it as flexible as possible.
The first part is rather a topic for [Academia.SE](http://academia.stackexchange.com/) and the second should be rather a standalone Community Wiki Q; can you please consider editing it?
Yes, exactly. You only need to consider the terms that include $\\lambda$ and compare with the Gamma distribution.
Thank you! You are right, fixed effects (for team) wouldn't do work since then I couldn't estimate the treatment effect (every team either receives treatment or not). Just to be clear: you propose a linear regression $y_i= b_1*treatment_{it}+constant+e_{it}$ with random effects on team level and a t-test for b_1? And intuitively, what this does is take out the group specific effect, right?
Thank you for the response. But first isn't d/dx(f(x) + g(x)) = d/dxf(x) + d/dxg(x)? and also the lambda here is actually a number right? so d/dx n where n is a number = 0 so that completely knocks out the right side of the equation?
Binning has absolutely nothing with helping to find a nonlinear relationship.
Have you drawn the q-q plot?
First, let me say that implementation is really nice! I'm a bit confused about the algorithm, though. How exactly did you add all those probabilities and not go over 1? I must be misunderstanding something. It seems to me that Naive Bayes would be just as easy in this situation. Did you try that and get strange results?
+1 Good points in the update, especially the last paragraph.  When the Hessian is available--as is implicitly assumed throughout this discussion--one would automatically use its positive-definiteness as one of the criteria for testing any critical point and therefore this issue simply could not arise.  This leads me to believe the Wooldridge quotation must concern the Hessian at a putative global minimum, not at a mere critical point.
I have downvoted this--pending some citation--in the belief that this has never been the meaning of "kernel" in the statistical or mathematical literature.  I would be very interested and grateful to be proven wrong, though.
@sxv Yes, that's right.  (Well, I actually used greater than or equal.  Ties do happen.  I think including equality among the significant results is the correct thing to do, because we're evaluating the probability that differences *this large or larger* can occur by chance.)
Consider breaking up your question into several parts with specific points. A question this broad is unlikely to be answered.
@user777, I dont know what you mean
1. So far, I dont know the response rate. But it would be nice if this prior knowledge can be used. (Maybe I can obtain it from the previous study, or I can make an assumption about it, say $p$)

2. Stratified sampling (e.g. by gender) is possible to improve precision. But so far, I would like to keep it simply as to simple random sampling.

3. I was wrong. I would prefer sampling without replacement.

4. We assume that there is no cost to handle non-response cases.

5. I dont have the exact number yet. But what if 1) N=$1000$ and $n=10$ or 2) N=$20$ and $n=10$?
I don't have a copy of either of those texts in front of me, Jase, but I suspect that they have assumed the estimates are Maximum Likelihood estimates (which is the setting for a Wald statistic), whereas your question asks about an "arbitrary" estimator.
Great answer, that's really helped me finally understand what an ANOVA is doing! Thanks also for the book reference!