tttjjj/elt_bench huggingface dataset:
I don't see what the importance is of having multiplicative parameters. Moreover, I gather this leads to a poor model. Maybe you should use an additive model. You may be interested in reading this thread: [How should I transform non-negative data including zeros?](http://stats.stackexchange.com/questions/1444/)
stackoverflow.com is probably a better place to ask this question, or r-devel list. I suspect that this is possible, but that is not the matter of changing some options. This means that probably you will need to write your own custom install.packages function. I may be wrong of course.
@whuber.you are only give to me the definition of $X^{-1}(\\mathcal F^\\prime)$
If the degree of freedom increases then the t-distribution get closer and closer to the normal. In the limit $n->\\infty$ it is normal. Already with $n=30$ you will not see that much difference anymore.
Suppose $X_1$ and $X_2$ are two variables, you'd only carry out one test, regardless of sample size. I don't see why you suggested there would be $n^2$ tests.
You have already answered your own question. Just re-stack your datasets, noting the group number in each dataset before you do it. Then estimate your model, with the appropriate group interaction term.
Right, but there's no better word for "I'm pretty damn sure it's significant, but I haven't done any tests on it, and won't, because it's obvious/can't be done/whatever"
This question appears to be off-topic because it is entirely about the use of R. It is not appropriate for SO either, because "please give me the code" questions are not welcome there. Please read the help about software-related questions.
Sorry I didn't express that very well, when I said "at any point" I meant along its entirety.
I though about this - fortunately I don't think it's a particularly likely scenario in my case.
I think this is an excellent way of explaining the probability distribution without relying on a rigorous mathematical proof.
Thank you for answering. The thing is that I want to simulate samples from a multivariate normal distribution, x~N(mu,Sigma), in order to find the probability that  {r(x) < 1}, where r(x) returns a positive real number based on the vector x. So I simulate x_i~N(mu,Sigma), i = 1..M, and I estimate the probability by the Monte Carlo estimate p = (1/M)sum{ I(r(x_i)<1)}. No problems so far. However, since {r(x_i)<1} is a very rare event, I want to try importance sampling instead, simulating from the distr N(mu2,Sigma2)-> I need the pdf value to estimate p = (1/M)sum{I(r(x_i)<1)*pdf1(x_i)/pdf2(x_i}
One problem with using QQ plots to interpret GWAS is that the p-values are not independent of each other, and, in fact, the most extreme p-values are very likely correlated.  I would guess that your top four hits are likely on the same chromosome and are close enough to each other that LD is causing correlation between them.  If you were to run the test that gave the second lowest p-value conditional on the SNP with the lowest p-value I'm guessing its p-value would drop into the unexceptional range.  The same would likely happen with many of the other apparent hits.
OK--I did not understand that was your interest, because it is not the subject of the current thread.  You seem to be answering some other hypothetical question about how to draw beta-distributed random variates.  This one only asks about computing the quantile function for arbitrary $B(a,b)$ at the $0.95$ quantile.
Do you have some demo data that can "tell the men from the boys" in terms of algorithm parsimony?
The maturity corresponding to the highest yield?
Got it, thanks very much.
You mention "daily" several times, but I still have to ask: do you really *need* daily forecasts? I'm not the expert on this, but it seems to me that you're creating a lot of over-fitting and noise issues by requiring daily forecasts.
No. Normal distribution theory effectively begins with Gauss and Laplace, (with perhaps one or two others around the same time, apparently independently of the big two). De Moivre discovered the formula for it a good while earlier, which he used as an approximation to a binomial coefficient, but wasn't using it as a probability distribution.
Ah, yes: if you have access to the original data, use it. Depending on what you want to do, it may be useful to have your categorical T, to break the model into parts, but the real work will be done with the original data.
One way to think of this is 95% CI is a "long run average".  Now there are many way to split up your "short run" cases so that fairly arbitrary coverage is obtained - but when averaged out give 95% overall.  Another, more abstract way is generate $ x_i\\sim Bernoulli (p_i) $ for $ i=1, 2,\\dots $ such that $\\sum_{i=1}^{\\infty} p_i=0.95 $.  There is an infinite number of ways you can do this.  Here $ x_i $ indicates whether or not the CI created with the ith data set contained the parameter, and $ p_i $ is the coverage probability for this case.
@Nick Ordinal implies discrete? Not necessarily. Continuous measures can be ordinal. For instance, physiological variables such as GSP or heart rate are continuous, but as measures of psychological variables such as anxiety or arousal they are only ordinal. The notion of ordinal vs interval really refers to the linearity of the function that relates the measure to what it is intended to measure.
Hypotheses are put forward about populations, not about samples.
The two things are not incompatible; what you subtract is a value that is also optimized along with the rest of parameters.
The key question is not so much the probability of the outcomes, but their sample sizes relative to the number of independent variables in the model. One rule of thumb is to have 10 cases in the smaller category for each independent variable.
Thank you so much. I discovered a half-answer to this already, but what you said clears things up a lot. Simulation variance is due to the inexact calculation of integrals. well said! thanks again.
You must make all the months to have an equal number of days. And then set frequency to that number. You can achieve that by discarding data, padding NAs or extrapolating. If you use lags smaller than 28, padding NAs is the easiest solution.
Re procedural constructs (e.g. looping): that sounds like a giant step backwards.  We are at the cusp of a change from single and small-CPU platforms to massively parallel platforms.  As this evolution occurs over the next decade or so, the easily and automatically parallelizable functional style of coding will reap huge advantages over procedural code.  Many other considerations intervene in one's choice of a statistical platform, of course, but this one is worth bearing in mind as a long term strategy.
I don't have any experience with those. Moreover, I am so dependent on do-files of thousands of lines that for me it really is worth it to resolve the problem in STATA. If I have to use other software than all the time invested in those do-files will be for nothing.
Does this relate to [biclustering](http://en.wikipedia.org/wiki/Biclustering)? That's a method for clustering both variables and cases simultaneously. See also [this previous Q](http://stats.stackexchange.com/questions/7419/getting-started-with-biclustering).
$\\beta_1=-32000$. All coefficients except for the intercept ($=\\beta_0$) are relative to card 1, month 1. Hence, $\\beta_1$ is the difference of card 2, month 1 to card 1, month 1. In this post there is some more elaborate explanation: http://stats.stackexchange.com/questions/60595/expected-value-from-a-regression-table/63173#63173
(+1) Regarding PCA, [co-inertia analysis](http://pbil.univ-lyon1.fr/R/articles/arti113.pdf) is one possible way to constraint the analysis in order to account for the two-block data structure (A and B), instead of running two separate PCAs.
Why are you interested specifically in the coefficient of variation? Wouldn't a comparison of the mean execution time be more meaningful?
Thanks! What is a good approach if it's not linear in the logit scale?
I've upload a PRBSquence of n=1000 to estimate for a HMM: [link](https://gist.github.com/anonymous/7453430)
Unless you truly do understand the math *and* are willing to undertake extensive tests of your modification, it is a poor idea to change any aspect of a pseudorandom number generator. Too much can subtly go wrong.
I see (I was too hasty and did not realize it was a marked point pattern). Things I have seen before are the estimate the voronoi tessellation of the points, and see the correlation between the areas and the marked values (e.g. more aggresive should have larger territories). A similar approach to what your doing now is to formulate the spatial weights matrix and calculate the spatial correlation (e.g. Moran's I). What you are describing is negative spatial correlation.
Thanks this really helped me out. This actually helped me out answer another question of mine!
Welcome to the site! Saying they "only differ" sounds a little strong, particularly since the sets of values they can take on are quite different. :)
Hi, The preferred distance is categorical-0.5km, 2km, 5km, I numbered them as 1,2,3 respectively. I did relate them separately in bivariate Chi-square test. But I believe, there is a relationship between importance level and preferred distance. For ex: medium importance may be opted with medium distance. If I combine these two, I could say that there these two variables act together in making the decision. thanks.
I was thinking about just looking at the absolute percentage differences across each category relative to actual values.
If there is more than one coefficient for the predictor in the model, you can't interpret any single coefficient very well.   A simple case would be having $x$ and $x^2$ in the model; you need to vary $\\beta_{1}x + \\beta_{2}x^{2}$ to get a hazard ratio of interest.
(1) Doesn't make sense. Do you mean "there are only a few non-linear effects"? In any case work out the total degrees of freedom used for regression. (2) The point's whether you already have all the data or not. If so there's no sense in discarding any. If not there's diminishing returns to collecting more "No"s. (3) If you're new to regression you need to study it before using it in earnest. Read [Steyerberg (2009), *Clinical Prediction Models*](http://www.clinicalpredictionmodels.org/) then [Harrell (2001), *Regression Modelling Strategies*](http://biostat.mc.vanderbilt.edu/wiki/Main/RmS).
I guess the probability vector is just what you sample with the Dirichlet distribution. Example : (0.5, 0.4, 0.1) is a vector and is used to represent the proportions/probabilities of a distribution of a variable with 3 classes.
I made a rather large edit to include some of the information you gave. Hopefully, this gives you some more ideas and hints.
I think my definition of "exploratory data analysis" is more narrow than yours.  In my view, all good data analysis involves exploration.  What distinguishes "exploratory data analysis" is the lack of a model or any effort towards formal inference.
Hi and thank you for your answer. Let me see if I understood well. If `M1=[m1,m2,m3,m4]` and `M2=[k1,k2,k3,k4]`, a permutation of this could be e.g. `[k1,m2,m3,k4]` and `[m1,k2,k3,m4]`? (I mean, the indices must always match, right?) Then we calculate rho for each one of those permuted sets with `HJ` set and we record the difference. Finally we calculate the percentage of those differences that are higher or equal to the original difference `rho(HJ,M1)-rho(HJ,M2)`, which is our (one-sided) p-value. Is that correct?
If you don't get any answers below, when I used SAS I found their technical support to be excellent in answering these sorts of questions.
Yes, you're right. The p value that's greater than 0.05 failed to reject the alternative hypothesis and the conclusion is that there is no significant correlation, namely accept the null hypothesis where correlation is equal to zero.
This says you are trying to predict something rare.  My take would be that you don't have enough good predictors of the "rare" cases.  If you did there would likely be more points in the 0-2 range.  Either that or there is a certain class of points that your model does poorly on.  Is your estimated intercept large in magnitude?
The tf-idf-Statistic For Keyword Extraction - http://www.joyofdata.de/blog/tf-idf-statistic-keyword-extraction/
Of course. I ll try to post it tomorrow.
It's not even clear what you mean by 'low sample data' (small values, or few data points?), let alone the rest of it. Please clarify extensively. I have no clear idea what you are asking.
I need to check.  Are you using Sigmoid as link function and independent training set and test set?
It is part of an assignment, but not compulsory. I know that there is a function that you can call it but in reality I believe that you should know how to it in order to improve the skills.
@Aniko Perhaps, I am missing something here. But, when I substituted the two sets of parameters into the likelihood function that I suggested they are not identical (assuming that I did not make any errors which is always possible).
Updated graph after Glen_b his answer
The factor analysis proves that it is related. Factor analysis does sometimes put one question by itself; in fact, the later factors are often one question by itself. You have shown that either "behavioral intention" is related to something else or that the question you think measures "behavioral intention" is also measuring something else. See my profile for more info about me, if you like, including my website
Be cautious with observed power: http://nottinghamtrent.academia.edu/ThomBaguley/Papers/212458/Understanding_Statistical_Power_In_the_Context_of_Applied_Research
"Elegantly overlooked"... that's a useful phrase for reviewing the literature if ever I've heard one.
This sounds like a problem in '*[inter-rater agreement](http://en.wikipedia.org/wiki/Inter-rater_reliability)*'
Whoa, that would be awesome. Please do @forecaster.
@Dean; The t-test is not testing Normality, it's testing the hypothesis that the distributions in your two groups are the same (or have the same mean). If you don't want to test that, analyze the data some other way. If you do want to test it, pre-testing for Normality (or equal variance) can do more harm than good, as this test is dependent with the one you ultimately report.
Thank you very much - I haven't been able to get with my coworker who knows much more R than me, but I'm sure this is the ticket.
This question appears to be off-topic because it is about statistics and has been flagged for migration to Cross Validated.
Thank you for the reply. Yes I chose my model based on the CV accuracy and partly from the ROC chart. But I was not too sure of the ROC chart because 2 of the models that I designed gave weird pattern on the ROC chart. Thank you for the link too. It sure helps me in writing my report :)
@NickStauner I estimate it by taking sample mean
Thank you! Maybe there are any nice articles adressing small sample size problem?
Simulation introduces errors which might be small, but which shouldn't be necessary for small values. If you have $k$ categories and $n$ objects, then the number of possible outcomes is $n+k-1 \\choose n$. When this is small by the standards of computers (perhaps less than $10^7$) then I would just use exact calculations. If the exact calculations are slow, test the errors of the simulations and see if they are acceptable for the speed increase.
@b2amen Yes I undersatnd BUT Glen_b wanted some "stuff" and I thought I would respond to him.
It can't be done unless you come to some objective criterion; probably most of possible ratings can be constructed with some combination of your parameters.
"attitude" doesn't seem to be normally distributed. Usually, such psychological measurements are assessed by some score which is only ordinal. ANOVA and t-tests are only for continuous and metric data. So you have to enter the realm of nonparametric statistics, where the Wilcoxon test resides.
using a procedure without reading the manual, and wondering why it doesn't make sense? :-)
And actually...there was an issue before with this KDE code when there was a replicate in the dataset. Computing a bandwidth failed. But, when I manually changed one of the replicates (e.g. + 0.0000001) it ran 'flawlessly'. I did not think about any relationship between that problem and this...but who knows? That's why I'm asking!
Agree; I just wanted to highlight it. Still I think that reduction of predictive accuracy can be removed by using proper training; in phylogenetics the similar problem (greedyness) is reduced by Monte Carlo scanning of the possible tree space to find maximum likelihood ones -- I don't know is there a similar approach in stats, probably no-one was bothered by this problem to such extent.
This is probably why you should finish reading the documentation before you jump into R.  The answer is discussed on page 5 of the dlm vignette, discussing time varying models.  If F is time-varying, dlm models accept a separate vector X (with values over time), as described by vector JFF.  There is a specific example regarding dynamic regression.
This is a wonderful answer, full of useful information--but it's wrong, for several reasons: (1) you overlook the effect of the reduced degrees of freedom in $t_{n-3}.$ This is profound when $n$ is small (which is exactly when $t$ distributions should be used instead of Normal distributions). (2) You overlook the effect of $\\tilde{x}^T(X^TX)^{-1}\\tilde{x}$: prediction bands can actually widen with more variables, such as when the new ones have little additional predictive value.
@gung thanks for the LR solution. I'm familiar with it.  LR makes sense if its a plot between Cancer and Age.  Chi Square investigates whether frequencies of certain categorical variables (such as Pass/Fail) is independent of the groups.  Eg, financial viability may be related to sector (esp airlines during oil-shocks).  Please don't end the discussion until we agree on whether Chi Sq is the better solution here.
+1 excellent answer.
I will have a look, thanks.
I'm impressed. I've seen some of Karl Weunsch's work before, on teaching statistics, and liked that too. Thanks for pointing this out, Jeremy.
Rolf Sundberg attributed this quote to J.M. Hammersley in a 1994 article: http://dx.doi.org/10.1016/0169-7439(93)E0041-2
I agree with Gael. People who design experiments, and people who validate scales are usually two different groups of people. If you are coming from a psychology background, and the only thing you've seen that dealt with numbers was in psychometric courses, you are up for some big surprises in discovering other areas of statistics if you are looking around with sufficient curiosity.
And what are the bars for. I mean for each point there is a bar. What is that for?
@gung: I am asking about any similar test or approach in Limma package that I can use.
You should not be using truncated regression just because you have skewed or bounded data. It is specifically for situations when values below a threshold (eg negative values) are possible, but would not be observed for some reason. Is that the situation you have?
Seems like a duplicate of this: http://stats.stackexchange.com/questions/62770/calculating-icc-for-random-effects-logistic-regression
Correction in my previous text 'WHEN Vuong test preferred ZINB'.I wanted to type 'Vuong test preferred ZINB'.Thanks
Doesn't matter; the larger model will likely have a worse fit, as you may be discovering unpleasant cross-loadings. The inferential framework of chi-squares and p-values assumes you've only fitted one model once. Any sidesteps, formally speaking, would obligate you to perform correction for multiple testing. People in SEM don't bother, and that's one of many reasons this field is so plagued with ad-hoc approaches inconsistent with one another, inconsistent internally, and lead to irreproducible results.
that's also what I suspected, but this sentence is clearly misleading..
It seems to me you'd only be losing important information if the probability of E varied with the duration and you were going to model it as a function of duration.  Explaining why you even care about duration might help...
@Ngu Nobody promised it would be easy. Expecting meaningful patterns just to magically emerge from a sea of data is what gives data miners a bad name.
Did you mean an SVM?  I do not think there is an easy way to get some measure of feature importance out of an SVM.  There are likely some wrappers to do permutation based importance scores however.  There are many hyperparameters to tune in an SVM though, so expect to spend some time getting reasonable answers.
With all due respect to Gary King, a program that claims to do everything for the researcher in a mysterious black box way is just dangerous. Besides, goodness of fit and endogeneity are unrelated (orthogonal, if you like) issues. You would certainly want to clarify your question and give a little example, preferably with `auto.dta`
But wouldnt P(W) still be 1001/2001 OR 1/2000?
See [this fantastic answer](http://stats.stackexchange.com/a/30205/6633) for a huge collection of bivariate nonnormal distributions that are marginally normal.
@cardinal : OK, I've added a few things.
There is often correlation between regressors (especially between lags of the same time series), but then the X'X matrix is near singular, and estimation is numerically instable (big condition number, hence values have low precision)
Just let me clarify first that, if the likelihood is flat, you do not really want that your sampler do not "move very far to the posterior tail". What is desired is to sample properly from the distribution (both, tails and centre). When using a MH algorithm with Gaussian proposals, you need to choose scale parameters/covariance matrix that determine the length of the steps. These have to be chosen for 1. Sampling properly from the distribution and 2. Getting a reasonable acceptance rate.
That's because the permutations were not exhaustive in your case, that was a Monte Carlo permutation significance test. In such a test, p-value is not a precise (point) probability but rather an interval about the obtained value of p.
Actually, a single observation of a random variable often provides information about that variable's variance.  It depends on the possibilities you allow.  For instance, a single observation from a Uniform, Poisson, or Exponential distribution lets you estimate its single parameter, which gives you an estimate of the variance.
But perhaps you can clarify a bit.  Call `matrix1` $A$.  Then what is $A_{ij}$? Is it the $i$-th person's reponse to the $j$-th Likert item?  Surely not.  So where does the average over participants come in?
@Dmitrij, I haven't tested it, but in my case I am confident the $\\c_i$ are not all equal (or approximately equal).  For instance, some classes are very similar to the outcome test, and other classes are not similar.  Those that are similar are sure to be better predictors.
FYI, in R (which I think the original poster is using) NA and missing are the same thing
@DilipSarwate - actually I don't know, and the paper doesn't say. The author goes on to discuss sample means $\\bar{x},\\bar{y}$ of $x$ and $y$, and $s^2(x)$ as the 'usual unbiased estimate of $V(x)$' and so on.
By predictor you mean I should use the initial level of x in year=1 as additional explanatory variable in my regression model? Well, I cannot do that in all of my models as I am estimating the ATT using a specific Stata command (psmatch2) that allows to include the additional variable in the equation to estimate the propensity score, but it is not possible to include additional explanatory variables to estimate the ATT on the outcome variable. Hence, I need to construct an integrated index, based on wi and diff.
Thanks for these clarifications! About the first point, I was just supposing the practice is to round to the closest cm. About the 2nd point I still need to read your dissertation to understand the algorithm and this notion of "weighted particles" which I have never encountered before.
Oh, I just realized that you said "write" not "report". My bad.
@MånsT Question updated to answer your questions