tttjjj/elt_bench huggingface dataset:
It is noteworthy--and, I'm afraid, not very amusing--that acquiring this short list of (excellent) books would run about $1000 US.  Perhaps one reason they are still so expensive is that the usual online resources aren't anywhere near as good or comprehensive.  (*E.g.*, yesterday I was looking for information about how inverse Gamma distributions might arise in nature--apart from their use as conjugate priors for Normal variances--and found *nothing* in the Wikipedia article.)
@NickStauner No, it was merely an observation that most of the critiques here (and indeed, in the rest of the internets) were on the data itself. Which means sense because the data itself is something most users here could easily criticize, while the actual details of the model aren't something I'd expect "Average statistician/Machine learning expert" to necessarily have encountered.
No. The binary variable is a factor variable with 2 values. So, normally with one-hot-encoding instead of binary variable risk.exposure.A, you would have 2 columns: risk.exposure.A.y and risk.exposure.A.n. But, because risk.exposure.A.y + risk.exposure.A.n = 1 (because of the encoding), which would be identical (and also collinear with interceptor column), you need to NOT use one variable. So, you would use from encoding only 1 of 2 variables, for example only risk.exposure.A.y. Build a model only with risk.exposure.A.y, risk.exposure.B.y, other numeric variables ~ dependent variable.
@Jessica. No I don't have a citation for that claim. But it is quite easy to show through simulation, formulas, or even just a basic knowledge of the factors that affect statistical power (i.e., such factors include alpha).
[Baum-Welch](http://en.wikipedia.org/wiki/Baum%E2%80%93Welch_algorithm) is capable of estimating the initial probabilities along with the transition and emission matrices. But I guess you opted not to use it. Is there a specific reason why the initial probabilities are important?
The split was done preserving the distribution of the outcome, the features space is also very small: 13 predictors, but some really not important. I don't know how to tune, perhaps I should try a different model, too...
Ah, sorry for the misunderstanding. The best source I know of is [this](http://research.stowers-institute.org/efg/R/Visualization/cor-cluster/). They study the quality of several metrics (that use correlation) with hierarchical clustering.                                                  For hierarchical clustering I normally try many metrics and see which works best for my particular goal and data.
A statement like that would imply a causal model.
I think John provided the right answer here. (+1)
I think you mean sent by fax at some point in the **past** ;)
Thanks Glen. I got the paper.
@garciaj I am not sure what the conflict is. Have you calculated $v^1$ and $v^0$ and looked at their relationship with $d$? If that does not resolve things, please clarify what the conflict is exactly.
Ummm... I guess someone at Minitab thought this was a good default? Every piece of software has some odd choices built in.
I would just make sure all the assumptions inherent in the t-test are satisfied and keep in mind there could be more complex (and interesting!) issues involved.  For example, in group A, maybe the inflection point depends heavily on some other parameter (call it p1) while in group B the inflection point depends on p2.  If the parameter interdependencies are the same for both groups, go ahead and use the t-test I think.
Just to clarify, you're saying that you have a lot of missing *labels*, correct?  You still have predictor variables for the unknown entries?
This thread may also be of interest: [Data APIs/feeds available as packages in R](http://stats.stackexchange.com/questions/12670/).
I notice that this post has gone awhile without an answer. For people like me, it would be easier to answer if you described your results fully in a paragraph rather than relying so much on this output that is unique to a single software application. (What is the "usual parametric analysis" exactly? What's anova got to do with Cox regression?)
Not quite sure what you're getting at: P is a function of E and E is a function of W, so forget about E and just say that P is a function of W. The aim of the training is to maximise $\\mathbb{E}[\\sum_v \\log P(v)]$ with respect to $W$.
I reference tau-b above and link to it. Most implementations of Kendall tau are of tau-b because it handles ties. However, I edited the title and text slightly to make this clear.
*Ad 1.* Your formula vaguely represents the variance of regression, and related indicators (such as R²) are commonly used as quality criteria. *Ad 2.* Why would you apply a *visual* method for parameter optimization? Why don’t you apply some sort of regression analysis to determine those parameter values that minimize the standard error of regression?
why do you use cross validation in a regression?
It's small numbers (small expected counts) where it's critical to model as count data. Whether there's a calculation problem at some size of count will depend on the software, but I don't see that a carefully implemented calculation should have a problem with those counts. Either way, they're certainly large enough to approximate by normal distributions, via nonlinear least squares or Iterative Reweighted Least Squares, say, but that, too, would need to be carefully implemented.
Thanks for the name. Didn't know it was called "transfer learning"
Check again. There is a difference between "error rate" and the probability of replicating an effect in a given sample from a population in which the null is true. The *p* value represents the latter, upon which one might choose to base the conclusion that the null is untenable. Error rate does not involve a given sample's effect, among other differences.
That is a wonderful reference book.
I don't think they are contradictory.  I can add some caveats.  But, in the general sense, without additional assumptions and knowledge about parameters outside of the presentation of the interval (the variance, the sample size) the response stands as is.  No, not a simple one at least.
how about `multcomp` package, regarding parametric models: http://cran.r-project.org/web/packages/multcomp/index.html?
@Glen_b I looked up nonparametric regression on Wikipedia, and I think that's enough to get me started.  Sometimes all you need is the keyword ...  I can research the rest.
If you are testing for normality, there are a lot of more specialized tests that are more efficient. Have you looked at a normal probability plot of your data?
@Harpreet: true enough, however, if your distribution has a finite variance, the central limit theorem ( http://en.wikipedia.org/wiki/Central_limit_theorem ) describes the asymptotic distribution of the sample mean. Since you presumably do not know the population variance, you would have to estimate that as well. see also http://en.wikipedia.org/wiki/Student's_t-statistic#Prediction
@user1231745 No, you start with 30 5-dimensional vectors and you end up with 30, nondistinct, 2-dimensional vectors (i.e. on a 2-dimensional grid).
impressive! Thank you!
$Pr(X=x)=Pr(\\frac{x}{n}\\leq U < \\frac{x+1}{n})$.  But from the hint, $Pr(a<U<b)=b-a$ so we get $Pr(X=x)=\\frac{x+1}{n}-\\frac{x}{n}=\\frac{1}{n}$.
Sounds quite along the lines of logistic regression to me.
Silver's methods have a Bayesian foundation. A natural way to assess the quality of predictions from that point of view is through wagers on the outcomes: how well would somebody betting based on the predictions end up? The worth of that seems eminently testable to me--and should be readily understandable by almost any sports blog reader.
It *could* make sense in some situations. I'm just mentioning possibilities. You're better placed to work out what does make sense. Is it really the case that values like $(10^{10000},10^{-4000})$ would be *just* as likely as $(10^6,10^5,10^{-2})$? If not, you should consider whether you have more knowledge than you're expressing.
The thing is I have used polyfit and got some coefficients say a,b,c,d. So, it is a nonlinear 4th order equation.(A)Should I then use this equation as a parameter for "modelfun" when using nlfit which asks for a model?(B)How do I know that the obtained equation is following an AR model or MA model or ARMA model?(C) Will nlfit give better coefficients,what is the benefit of doing nlfit over polyfit?
I'm not sure how this answers the question. Frequentists of course disagree with desideratum 1 from this list, so the rest of the argument doesn't apply to them. It also doesn't answer any of the specific questions in the OP, such as "is Bayesian analysis more powerful or less error-prone than a frequentist analysis".
@Pinocchio $\\mu$ is the vector of dual variables (Langrange multipliers) associated with the slack variables $\\xi$.
Zach Not sure where it is at in development stability, but GBM on R Forge has multinomial logistic as a loss function allowing multi category classification.
(-1) Model is selection involves too many considerations for your "definitely always" statement in paragraph 1 to hold true.  Also, it doesn't seem right to conclude that just because x2 only takes 4 values it cannot be closely associated with x1. For all we know, the mean of x1 might depend in large part on the level of x2, which could be group membership, region, industry, type of apple, etc.
As an aside, I have an inkling that you could create confidence intervals around $\\bar{X}$ and $S$ and calculate $\\beta$ under 5% and 95% case scenarios (or maybe 9.75% and 90.25%) and thereby create a confidence interval for $\\beta$ that would appropriately reflect the uncertainty of the sample estimates of the population parameters.
Thank you for the suggestions. These are what I'd normally do with this kind of data. However, as I hope to explain in my edit, I really want to try something different.
Apologies if not clear. An example.  Player 1 picks number 4.  In round 1, he faces player 3 who picked number 2.  Player 1 goes through, player 3 goes out. In round 2, player 1 faces player 4 who picked number 5.  Player 1 goes out.  The duration of the game would be 2 rounds (x=2). I am looking for the probabilities of X where x=1-4 for a randomly picked player.
+1 to @Sven. Just one note: There is, I believe, some software which reports AIC just inverted from the above, so that higher is better. I remember this from a few years ago, and am not sure which software it was. However, `SAS` includes "lower is better" on some output re AIC, just because of this confusion.
I am not sure which is better, frankly. Someone else here may know (lots and lots of knowledgeable people here)
Ah sorry I just got what you mean. Usually in linear regression you work with an input vector and a parameter vector, giving you one output variable (the data is then in matrix form). What you want are several output variables, right? The consensus on this in another thread was that you should probably do a regression for each individual output variable in the vector, as a combined approach usually does not hold additional information or is mathematically equivalent. Sometimes you have restrictions to take into account. Search for interdependent equation systems, as an example in econometrics.
I do not like the @MathematicalOrchid characterization that the KS statistic depends only on "one extreme point". The location of that "one point" (often in the middle of the distribution) in a CDF depends on the values of the other points in the set and so is not as isolated or solitary as that language would suggest to the naive listener.
@Srikant (+1) Interesting links, thanks.
This is a good Excel solution. I haven't checked recent upgrades of Excel, but previous versions had *terrible* implementations of `TINV`.  They break down in the tails; it's really noticeable beyond (approximately) the 99.99 and 0.01 percentiles.  Not a problem for quick-and-dirty work, but when you start using t-variates in simulations and for other calculations, the errors quickly become serious.
(1) The payoff for the experienced poker player has little to do with the *numbers* of negative- and positive-expectation decisions and everything to do with the net expectation of the collection of decisions.  If I play 20 hands and bet a tiny amount on 19 with negative value and go all in on the 20th, with positive value, I can expect to do better than someone who bets a little bit on 19 hands with positive value and a lot on one hand with huge negative value.  (2) The decision whether to play a hand or not is important, but you seem to be neglecting that altogether.
Thank you for coming to respond to this question!
This is a very common miss-understanding and perpetuates a somewhat caricatural view of modern robust procedures so i will address it here. The aim of modern robustness is not to delete observations that are somehow nonconforming but to limit (or bound) the influence any single observation is allowed to have on the final estimate. If you can identify a small subset of the data, that when down-weighted, completely changes the estimated results, then, it's just common sense that that subset has to be set aside (and perhaps studied separately) from the rest of the data.
Actually you are right, instead of let the graph evolve etc. Just by projecting the first two first components of a PCA procedure would do the job.

Thanks, I got obscured by my own thoughts and you pushed me out.
@Patrick So you think it shouldn't matter? I have results from a Shapley Value Regression test, and they are not matching semi-partial correlation values I get. That's what I don't understand...
I don't see that this of itself implies dependence. If the (population mean) background is constant across observations, you would expect to have independence. Even if there's some random noise in the background (so all observations have some common, unknown random shift) then that effect is eliminated when you take the difference in means (so you can still treat them as independent). If there's variation in background that tends to make some observations more alike than others, that would imply some form of dependence that needs to be dealt with.
Welcome to the site, @Andrew. This question seems to be *only* about how to get something done in R. As such, it would be off-topic for CV (see our [FAQ](http://stats.stackexchange.com/faq)), but on-topic at [Stack Overflow](http://stackoverflow.com/). If you have a substantive question about statistics, please edit to clarify, if your only question is about programming, flag your Q & we can migrate it for you (*please don't cross-post, though*).
Hi Paul, I didn't want to eliminate the thoughts you put into a reply, so I appended them as an edit to your question.  You ought to go through your question once more and digest it into the essential information, because it has gotten so long that few people are likely to read it through.  If you're unsure what our guidelines are for questions, comments, and replies, then please take a couple of minutes to consult our [FAQ](http://stats.stackexchange.com/faq).  Thanks!
the data do not even have to be from a uniform distribution, they can be from any distribution. also, this is only true using the formula you provided; data can be normalized in ways other than using z-scores. for instance, IQ scores are said to be normalized with a score of 100 and standard deviation of 15.
Thanks Greg.  I'm leaning towards the customized maximum likelihood approach.
Without an intercept term, $R^2$ can no longer be interpreted as the coefficient of multiple correlation.. is that what you are referring to? Or do you mean the general interpretation of $R^2$ as informing about the fit of the model relative to the mean of the response?
See http://robjhyndman.com/hyndsight/dailydata/
It is gratifying that superintelligent space monkeys also sometimes have trouble with R.
For the constant, known frequency case, it probably still breaks down further into whether you assume coherent detection or not (i.e., do you also know the *phase*)? At any rate, something like the empirical signal power should be close to a sufficient statistic when integrated over one period. Have you looked in, e.g., H. V. Poor, *[An Introduction to Signal Detection and Estimation](http://www.amazon.com/Introduction-Detection-Estimation-Electrical-Engineering/dp/0387941738)*, 2nd. ed., Springer? It almost surely does the entire development for *very* similar problems.
This should probably be community wiki since there is no definitive answer.
@Stephane Laurent: The surfit() function outputs the estimated survival at event times. But I'd like to have an automatic procedure to compute that survival at any time t. Thanks...
What you have supplied is a chapter from a book. Prescinding from the question of whether you have violated copyright by posting it, it would at least be a courtesy to the author to supply a citation.
Model validation is best done in my experience using the Efron-Gong "optimism" bootstrap as implemented in the R `rms` package.  This takes for example 400 resamples (400 model fits and evaluations).  Or you can do 100 repeats of 10-fold cross-validation.  The problem with data splitting is that you split again and get significantly different results.  Note that if you started with two terms in the model and ended with two terms, there is very little to overfit and so little need to validate [but then you wouldn't be using knn].
Thank you Dougal, I will keep that in mind for the future.
+1 Very good answer. Two thoughts: I would indeed recommend *Modern Epidemiology* as a book, though its not a great introductory book - it's a more advanced treatment of the topic. The other distinction I would make is "Lifetime morbid risk" is not only a unfavorable event, but one that does not kill you. It is often of interest to split out morbidity from mortality for diseases that might either kill you, or have lingering, lasting complications (heart disease for example).
Accepted the answer, I think the KS-statistic is what I need after all.  Ultimately I am looking to test the quality of a particular sampling technique, for this analysis I can stick to functions where the the cdf is known, and estimating it online is not really required.
If I use names(dat) instead of c(xVar,traceVar) when renaming newdata prior to using predict, then predict doesn't do what I'd expect. I'm sorry that my previous example code was unclear.  Now, I've provided a more clear example above.  What I want is to find the predicted y value at the mean, 1 SD above of the mean, and 1 SD below the mean for each predictor.
Could you provide a reproducible example?
@steko I don't believe anybody is claiming $R^2$ can be negative.  Where John refers to "true correlation" he means $R$.
+1 for Golub and Van Loan. And, yes, the definitive article is appropriate.
Could you please clarify what you mean by estimates. Do you mean, for e.g., that you want to test the overlap between height and weight for boys? Or, do you want to test the overlap between boy height and girl height?
(+1) This is basically what I did [here](http://stats.stackexchange.com/a/6023/930).
I like the book too, but the OP didn't really ask about Econometrics.
Are you wondering about anything else about the related statistical content? If your only question is about how this R package works, this Q is off-topic for CV (you may want to read our [FAQ](http://stats.stackexchange.com/faq)). My guess is this would then be best asked on the r-help list serve. If you have a statistical question, please clarify it, otherwise this Q will need to be closed.
+1 - a slight amount of jitter and making the points smaller and semi-transparent in the original plot would make it more informative as well (which takes minimal data manipulation). I can't figure out the precision of the values on the x-axis - but they already appear to be "clumped together" as the circles overlap exactly.
Thank you for the clarification =)
@Queops I added tags to provide links to useful threads.  As a hint, consider that $Y$ is a random variable that counts a certain number of things out of 25.  What distribution do you suppose it might have?  What do you need to know about that distribution?  The assumptions about the distribution of $X$ are there so you can compute the chance that a *single* baby has low birth weight.
@Aidan Plots? All I can see are black boxes. Are you sure there is no problem with the rendering on this page?
@Matthew Just to nitpick a little, the result $P(A\\mid B) = P(B\\mid A)$ does not hold _only if_ $P(A) = P(B)$ since it also holds when $P(A\\cap B) = 0$ in which case whether $P(A)$ equals $P(B)$ or not is not germane. One of my favorite True/False questions is the pair  "If $P(A) = P(B)$, then $P(A\\mid B) = P(B\\mid A)$" followed immediately by "If $P(A\\mid B) = P(B\\mid A)$, then $P(A) = P(B)$"
(+1) Thanks for these additional references.
If you use a complex survey design, as the OP said, you must use the correct procedure for estimating the standard errors of the estimates, svycoxph does this, and extractAIC on a survey design object does not work
The Liddell's exact test is an exact alternative to McNemar's test.
IMO this interpretation is based on the fact that it is darn hard to find any large effect sizes in social science, whereas in other disciplines may run the rule that the threshold for large is 0.9.
There are only stupid answers (-;
If your data are longitudinal (multiple measures on multiple patients) we're playing a different ballgame. You need to differentiate between changing residual variance for each individual's data vs diverging individual trends over time (which is common). You can fit a mixed effects model w/ random intercepts, slopes & a correlation b/t them, get predicted trends for each patient & their individual residuals. The key question is: does that variance change over time?
Thanks for your answer, I had been trying to find that Duke website for ages, but had forgotten the university name and so wasn't getting very far! I wish I could give you more than +1.
Welcome to the site, Douglas.
+1. I used to be enamored with GA's, but now tend to avoid them. It seems to me that they went through a hype phase, inspired a bunch of analogous-to-nature methods (ACO, etc) and then faded back into a niche. Sort of like Neural Nets, in my personal bias. (That said, I have used ES recently.)
I am using graphpad prism. Tukey is easily implemented using this program.
This is the right approach, but the solution can be obtained in a *much* easier fashion: having rasterized a density estimate, all you need to do is invert the cumulative sum of the values on the raster.  This is much faster and simpler than looping over values and plotting contours.  (This question was asked several years ago [on the GIS site](http://gis.stackexchange.com/q/19629/664); answers include working `R` code, which requires all of six lines to find and display the solution.) A closely related question appears at http://stats.stackexchange.com/questions/63447.
That's how I'd test against an alternative of greater-than, yes.
I'm not sure, but I suspect the answer is the same as [Significant t-test, but non-significant F statistic](http://stats.stackexchange.com/q/24720/7290).
Here $X$ is a quantity of interest (you did not define… presumably something like the mean of your data), and $\\mu$ is the mean of $X$ (the first moment).
Have you read Baayen, Davidson, Bates (2008), "Mixed-effects modeling with crossed random effects for subjects and items"? It can be found at http://www.ualberta.ca/~baayen/publications/baayenDavidsonBates.pdf
The whole theory behind what you are doing, how the tests work, and what they mean differs between the Bayesian and frequentist approaches to statistics. It is generally not best to mix them, it will just lead you into problems, as apparently it has done here. To learn more about all of this, it may help you to read our threads categorized under the [tag:bayesian] tag.