instruction
stringlengths
9
38.7k
I am of the knowledge that to test whether a data set approximates a normal distribution, the median and the mean should be approximately equal. So my question is to what degree should the difference between the median and the mean be accepted?
I'm doing least squares estimation on large set of data and I started to wonder whether I should regularize my OLS estimator. My professor told me that this isn't necessary, because the data is overdetermined. Could someone explain to me why? Why isn't regularization required with overdetermined data? Thnx for any hel...
I have a rather complicated model that I am testing on a panel data set, containing 3 categorical variables and 3 continuous ones, where I want to specifically test for the interaction effects between the categorical and continuous variables. So far, I have used, in Stata, fixed effect and random effect regression, bot...
I have two paired variables, x and y: person x y 1 124 100 2 79 94 3 118 105 ... Here is a scatterplot of the data: I am interested in the correlation between x and y. Bootstrapping gives me the following distribution. The lines are the actual correlation of the data (rho = 0....
Suppose I have matrix $X \in R^{n \times m}$, where $n$ is the number of individuals and $m$ is the number of features and $X[i,j] \in \{0,1\}$; $1$ indicates that the individual $i$ has the feature $j$, and $0$ means not. Individuals only belong to one of the two classes. Given a distance metric $Dist$ (any distance),...
I have carried out cluster analysis and now want to compare means between variables in different clusters. The variables in question are age and expenditure in millions of dollars. The age variable does not follow a normal distribution: as a result, I was considering a Mann-Whitney test. The expenditure in millions of ...
I am wondering what the exact relationship between partial $R^2$ and coefficients in a linear model is and whether I should use only one or both to illustrate the importance and influence of factors. As far as I know, with summary I get estimates of the coefficients, and with anova the sum of squares for each factor - ...
I've started with a “perfect” image 'without noise'. Then I added some noise to it. I've used gaussian white noise for this purpose. In = In+0.5*randn(size(Io)) The combined image (my “noisy image”) has a signal to noise ratio with some meaning because I can compare it to the perfect image. My question is how can I ca...
I have some Directed Acyclic Graph trees representing biological features. In my database, I can retrieve all the links between every child and its ancestors: I have all the edges and the nodes. Unfortunately, I have not only the direct links between every child and its parent, but I have also the indirect links betwee...
In this comment, Nick Cox wrote: Binning into classes is an ancient method. While histograms can be useful, modern statistical software makes it easy as well as advisable to fit distributions to the raw data. Binning just throws away detail that is crucial in determining which distributions are plausible. The context...
I would like to correctly specify that my data is temporally pseudo replicated in a mixed effects model in R using lme() of the nlme package. I have done this following the example in Crawley's R text book, but I need some confirmation that the fixed and random effects are specified correctly. I have checked previous p...
Has anyone any idea how one could distinguish time series according to certain properties? The only time series properties I know are stationarity/nonstationarity and homoskedasticity/heteroskedasticity. But are there any other possibilities to distinguish time series?
I have an ARIMA(0,2,1) model. How do i estimate the $\hat{e}_t$ component of the model. I have read a whole lot of theories that confuses me the more. Is there any practical way of estimating this $\hat{e}_t$? Does R offer any help to that too? I know that my ARIMA(0,2,1) model can be written as $Y_{t} = 2Y_{t-1} - Y_{...
I have read that leave-one-out cross-validation provides a relatively “unbiased estimate of the true generalization performance” (e.g. here) and that this is an advantageous property of the leave-one-out CV. However, I don't see how this follows from the properties of leave-one-out CV. Why is the bias of this estimator...
I have this mixture of a shifted binomial and discrete uniform: $$ P(R=r)=\left\{ \pi\binom{m-1}{r-1} (1-\xi)^{r-1}\xi^{m-r}+(1-\pi){1\over m}\right\} $$ Having fixed $\xi$, $\pi$, $m$ to be specific values, how can I generate N values for the random variable $R$? Let's say for example N = 100, 300 and 900.
What is the basic argument upon which ridge and lasso regression are based on? I went through Tikhonov regularization wiki where it was mentioned that In many cases, tikhonov matrix is chosen as the identity matrix , giving preference to solutions with smaller norms. In other cases, lowpass operators (e.g., a di...
Given a probability density function (pdf), $$P(x) = \frac{f(x)}{\Sigma_x f(x)}.$$ Is this still a valid pdf if the normalizing constant in the denominator, $\Sigma_x f(x) = \infty$?
I have a biological problem which involves using a 1-sided two-sample t-test. To simplify the problem, let’s assume an experiment comparing quantities in a control (C) and a treatment (T) group, each having 3 replicates, called C1, C2, C3, T1, T2, T3. Here, C1 and T1 are samples from the same subject, C2 and T2 are sam...
I have responses to a questionnaire item from a number of people, measured at equidistant timepoints. I wish to fit a growth mixture model (in R, using the LCMM package) to this data to find latent classes. My data looks something like this: ID item-response timepoint ----------------------- 1 3 ...
The Area Under ROC curve (AUROC) is a quantity used to quantify performance of classifiers. I am currently interested in the most basic drawbacks of using AUROC as unique performance measure. I got a negative feedback with AUROC in some recent analysis as I met a classification problem performed through a logistic re...
I have done an experiment with 7 treatment conditions designed to reduce alcohol intake, and a control condition. The dependent variable is alcohol intake after treatment, and I have run an ANCOVA with baseline alcohol intake as a covariate. I found no effect from the omnibus ANCOVA F-test, but wanted to investigate sp...
I'm using a molecular biological method which requires the following normalization $$Q = \frac{A}{\sqrt[k]{\prod_{i=1}^k B_i}}.$$ How can I find the standard deviation of $Q$, given that $A$ and $B_i$ have known standard deviations? Unfortunately my math training is not good enough for me to solve this. Is there some k...
First of all, please excuse if I don't use the proper terminology for this problem. I have a markov chain composed by two states: When in state 1 the output is drawn from an exponential distribution with mean parameter mu_exp When in state 2 the output is drawn from a gaussian distribution with mean mu_gaus and standa...
I have another problem with 14000 features and 500 training samples. It is a binary classification problem and approximately in the form of an ellipse. My classification accuracy using the 2nd degree polynomial Kernel and via CV is ~ 80%. However, I've randomly tried projecting the data onto 2-D, that is I just pick ou...
I have a response variable and number of predictors. I need to calculate the percent contribution of each predictor. I know that this can be done using Shapley value regression, but is there any way to do it through SPSS, Excel, or Minitab? Is there an alternative method, similar to the Shapley value method?
I have three variables: GENDER {“Male”, “Female”} AGE {“0-18”, “19-30”, “30-60”, “60+”} REGION {“Europe”, “Asia”, “Africa”, “America”} From the literature I “know” that: Males who live in Asia and who fall into 19-30 age group have 5% probability of having certain disease. Males in general have 3% probability of hav...
i am working to create a mapping of the adjacencies between 100 consumer goods. I have created an adjacency matrix based on product characteristics, and then create an i-graph of the graph/network (using tkplot / igraph) I am using the fruchterman reingold force-directed mapping algo to place the vertices, and get a ni...
This post follows on from this one. I am trying to analyse a dataset: $S$ subjects were tested for $A$ measures in $B\times C$ conditions. I have worked out that I can perform a repeated measures analysis by using a mixed-effects design where the subjects are random factors. Then I am left with a '3 way' $A\times B \ti...
Will each of the following increase, decrease, or have no effect on the value of the test statistic in a one-independent sample t-test? The sample size is doubled The level of significance is reduced The sample variance increases The difference between the sample and population mean increased This was given as par...
The standard error of prediction in simple linear regression is $\hat\sigma\sqrt{1/n+(x_j-\bar{x})^2/\Sigma{(x_i-\bar{x})^2}}$. My question is to calculate the standard error of prediction for $pop=1029$ just based on the following regression output. I can get all except $\bar{x}$. And I also know how to calculate the ...
I am trying to fit an unobserved components model for revenue and transactions for a firm where I also use some exogenous variables that capture economic conditions. The UCM decomposes a time series into trend, seasonality, an idiosyncratic component, and up to 3 cycle(s) using a Kalman filter state space approach with...
I am trying to compare 2 computer programs, X and Y, for speed. I want to determine which one is faster. I could, for example, chronometer those programs 20 times, take the average and state that the program with the lowest average is the fastest one. I don't know much about statistics, though - is that what I'm doing ...
I have a meta analysis at hand. I have reported on the quality of the included studies in a narrative form. But after I was requested about "quality assessment". I guess it might be something else, a statistical model for example, something like weighting. I googled it but to my surprise, no good links were found in th...
Suppose I have a discrete distribution defined by the vector $\theta_0, \theta_1, ..., \theta_N$ such that category $0$ will be drawn with probability $\theta_0$ and so on. I then discover that some of the values in distribution are so small that they underflow my computer's floating point number representation, so, to...
I'm using R, but the density function requires the actual samples, but I only have the histogram data. Can I still use kernel density estimation, or is there a better tool for this?
I am using a random forest code to run one random forest model and distinguish which variables are important for classification and then to run a second random forest model using only these variables to reduce noise. The problem is that different variables are added to the model on different iterations of this process....
Given the following Bayes network: with $p(k=t)=.2$ $p(o=t)=.1$ $p(s=t|k=f,o=f)=.0$ $p(s=t|k=f,o=t)=.2$ $p(s=t|k=t,o=f)=.5$ $p(s=t|k=t,o=t)=.95$ how would I calculate $p(s=t|o=t)$ and $p(o=t|s=t)$? I tried the following way: $p(s=t|o=t) = \dfrac{p(s=t \land o=t)}{p(o=t)} = \dfrac{p(s=t)p( o=t | s=t)}{p(o=t)}$, whic...
I am looking for a classification algorithm that emits probabilities for each label and supports real-valued features. 1) From what I gather, logistic regression may output a variable in $(0, 1)$, however, it does not describe the true classification probability. 2) Naive Bayes supports probabilities, however, it uses ...
I guess this is a quite basic question, but I have been struggling with this for quite some time, so I hope someone can help me with this. I have a model (type is not relevant for now) which includes a linear predictor (LP) that would normally be calculated as: LP = sum(coefficient1*predictor1, coefficient2*predictor2,...
The Situation: I have four similar spatial regression models, differing only in their dependent variables. The independent variables consist of a standard set of variables derived from a principal component analysis. The dependent variables have been standardized by using the standard score for each observation. The Qu...
I am not very well knowledgeable in statistics as I have yet to take a formal class in it (but have signed up for one next year) and yet find myself in need of finding out whether or not a single data point in a list of values is statistically significant. My data is a list of 4000 values (a power spectrum to be exact)...
Is it possible to apply the usual MLE procedure to the triangle distribution? - I am trying but I seem to be blocked at one step or another in the math by the way the distribution is defined. I am trying to use the fact that I know the number of samples above and below c (without knowing c): these 2 numbers are cn and ...
Suppose that I have a new way of estimating covariance matrice (from a particular data set), and that I believe this is better than the sample covariance matrix. I want to fit a t-copula with this new covariance matrix, and assess how good this particular choice of copula and covariance matrix (vs. say the gaussian cop...
I have two vectors of 100 real values each. I would like to use a permutation test for a few things such as the correlation of the two vectors. I would use the approach of keeping one vector stationary and then permuting the other in relation to it and then calculate the statistic of interest (such as correlation) on...
I'm looking at a data set and trying to understand relationships between what is charged and what is paid. First pass with a simple regression using excel's data analysis regression tool gives the following, without forcing zero intercept: Second pass with forcing zero intercept: I get better R squared values (0.82 v...
I have a table. CASH CREDIT CARD DEBIT CARD TOTAL UNDER 20 0.09 0.03 0.04 0.16 20-100 0.05 0.21 0.18 0.44 OVER 100 0.03 0.23 0.14 0.4 TOTAL 0.17 0.47 0.36 1 The question is: “F...
“Determine probability that a purchase is paid for by debit card OR credit card given that the customer paid over $100 for it” [2 events and 1 condition] “Compute the probability that a child survives an accident given that the child is either 3 OR 4 years old.” [ 1 condition, 2 events] My question is, how is this han...
I have learned several classifiers in Machine learning - Decision tree, Neural network, SVM, Bayesian classifier, K-NN, Markov process...etc. Can anyone please help to understand when I should prefer one of the classifier over other - for example - in which situation(nature of data sets, etc) I should prefer decision t...
I would like to know how about the differences between hidden markov model and neural network.
In local news [1] comes with information that 58% of people is for something. This information is based on option pool that ask 500 people from 10.5 million about that question. What is confidence interval for people that are for that something? To solve this I try following. The $n$ people from $10^7$ is for something...
Background: I have two random variables - height and weight. We often estimate correlation between them based on random sample of individuals. However, what would happen if I took only one individual and measured his weight and height in many points in time. Questions: What is the limitation of such approach? Is corre...
I am trying to estimate the probability of an event using a low number of observations. The naive estimator $\hat{p} =\frac{\text{number of positive observations}}{\text{total number of observations}}$ works well when the total number of observations is big enough, but if you have only a few observations, there is a de...
There is the notion of Generalized RBF Kernels, for example in "Towards Optimal Bag-of-Features for Object Categorization and Semantic Video Retrieval" from Jiang (1) or in formula (2.72) in http://agbs.kyb.tuebingen.mpg.de/lwk/sections/section23.pdf (2). They define: Gen. RBF Kernel: $e^{-pd(x,y)}$, where (1) says d c...
I want to include sample weights to my quantile regression model, but I'm not sure how to do this. I've already define my weight, which are replicated weights already given in survey dataset (computed in survey package): w<-svrepdesign(variables=data[,1:10],repweights=data[,11:30],type="BRR", combined.weights=TRU...
I am trying to apply R depmixS4 package in order to cluster time series with model based clustering. The model consists of K components, each being a first order Markov models. The Expectation-Maximization algorithm is then used to estimate model parameters. My time series are multivariate and of arbitrary length ( i....
Currently iam working on my master thesis which is about risk adjusted returns in the Asia Pacific REIT market. The goal of the paper is to determine/find variables that conceive explanatory power over the IV. To determine this I also performed a FE regression based on countries. The result are more or less in line wi...
How much validity is there in doing external hand hygiene observations in a hospital where another facility observes for a total of 6 hrs. twice a year and reports that data out, when the observed facility already has their own internal hand hygiene observers to obtain there own data monthly?
Can anybody please explain or point to an online resource that explains the Fourier phase randomization technique? I encountered it in the context of comparing the cross-correlation of two signals before and after Fourier phase randomization. What does it mean when the cross-correlation disappears after Fourier phase r...
My understanding is that with cross validation and model selection we try to address two things: P1. Estimate the expected loss on the population when training with our sample P2. Measure and report our uncertainty of this estimation (variance, confidence intervals, bias, etc.) Standard practice seems to be to do repea...
I would really appreciate if someone could help me with this question. I want to simulate $n$ datasets in R with eight predictors where $β=(3,1.5, 0, 0, 2, 0, 0, 0)$ and the pairwise correlation between $x_i$ and $x_j$ is set to be $\text{corr}(i,~j) = 0.5$ for $i-j$ or for all $i=j$.
I am aware of this question here, which mine was listed as a duplicate of, but it does not fully answer my question. It did however help me progress a little further so thanks, I couldn't find it before. The online calculator on the above answer also disagrees (though marginally) with the vassarstats.net calculator so ...
There are 4 subjects and 4 measured data of each subject and the data should be interpreted in the context of a mixed model. What is a reasonable estimation for the covariance of y? y <- data.frame(response = c(10,19,27,28,9,13,25,29,4,10,20,18,5,6,12,17), treatment = factor(rep(1:4, 4)), ...
I've got a set of N independent measurements that I'd like to do a weighted average on to get one, hopefully better, measurement. I've got a variance measure for each measurement, would it be more appropriate to use the inverse of the variance or the inverse of the standard deviation as my weights?
I have extracted 7 factors from 25 variables using principal component analysis with varimax rotation. Now I want to use these factors as independent variables and study their relation with an ordinal dependent variable. For this I applied multinomial logistic regression in SPSS. But it gives me a warning that a number...
I have a problem where I need to identify from which subject a particular set of data points came. More specifically, my problem is that I need to demonstrate that my subjects (N=9) can be discriminated from one another, with the future goal of classifying them based on the IV's. Each subject has repeated measures of t...
I am doing a numerical experiment involving comparing Approximate Bayesian Computation (ABC) with other methods. I am simulating data $\boldsymbol{y}$ from a model and I'm using ABC to get a sample from the posterior of the parameters $\boldsymbol{\theta}$. The summary statistics $S(\boldsymbol{y})$ are on very differe...
I'm facing a text classification problem, and I need to classify examples to 34 groups. The problem is, the size of training data of 34 groups are not balanced. For some groups I have 2000+ examples, while for some I only have 100+ examples. For some small groups, the classification accuracy is quite high. I guess thos...
I am conducting (somewhat casual) research on the accuracy of several algorithms meant to compute a value when given a set of experimentally gathered variables, including time. The issue is, the true value is not available to me, and I have no way of experimentally determining it. Is there some way of quantitatively co...
I'm using the library vars in R to plot fanchart and predictions through the vector of error correction model. I have used this code: b<-ts(KtF,start=1921,end=2009,frequency=1) vecmfemales <- ca.jo(b,type="trace",spec="transitory") vecm.level <- vec2var(vecmfemales, r = 3) vecm.females <- predict(vecm.level,n.head=50,s...
If $S$ is the sample space of some discrete random variable $X$, what is usually given as its superset? $S \subset \mathbb{R}$ or $S \in \mathbb{Q}$? The $X$'s I have are digitized biomedical data. Edit I'm writing an introduction to biomedical data analysis. As a part of it, I must provide some introduction to statis...
$C_{MAP}$: most likely class (i.e., "maximum a posteriori") $C_{NB}$: Naive Bayes x: document d is represented as $x_n$ features or words $c_j$: I think it's a class j Source is here on page 27: http://www.stanford.edu/class/cs124/lec/naivebayes.pdf Anyway, $$ \begin{aligned} C_{MAP} &= \mathop{\text{argmax}}_{c\i...
I am implementing M-spline in R as defined here : http://www.fon.hum.uva.nl/praat/manual/spline.html and originally in Ramsay (1988). In short, we define a list of knots $t$ such that : $0=t_1=...=t_k<t_{k+1}<...<t_{k+m}<t_{k+m+1}=...=t_{k+m+k}=1$ So the $k$ first knots are 0 and the $k$ last knots are 1 with $m$ inne...
Maybe this question has answer in medicine, but are there any statistical reasons why BMI index is calculated as $\text{weight}/\text{height}^2$? Why not for example just $\text{weight}/\text{height}$? My first idea is that it has something to do with quadratic regression. Sample of real data (200 individuals with wei...
I'm trying to understand the whole variance/std error thing of a time series of financial returns, and I think I'm stuck. I have a series of monthly stock return data (let's call it $X$), which has expected value 1.00795, and variance 0.000228 (std. dev is 0.01512). I'm trying to calculate the worst case of the annual ...
The setting A user is presented with a number of options related to her search query. She chooses one of them. As a result, a payout is generated. The payout lies in the range [0.05, 0.50], but the payout of each option is not known. The total number of options is $n$. Observable data For each day, only aggregate dat...
I have data in the following format: id yrdx yrsrv dead 1 2000 3 1 2 2003 10 0 3 2004 5 0 4 2007 1 1 where yrdx indicates the year of diagnosis for a disease, yrsrv indicates how long an individual survived, and dead indicates whether or not they died or were censored. I would like to plot death rat...
In Woolridge's econometrics book, he gives the homoskedasticity assumption $${\rm Var}(u|x)=\sigma^2 .$$ He also says Because ${\rm Var}(u|x)=E(u^2|x) - [E(u|x)]^2$ and $E(u|x)=0$ then $\sigma^2=E(u^2|x)$. This means that $\sigma^2$ is also the unconditional expectation of $u^2$. Therefore, $\sigma^2 = E(u^2)$. How ...
I have a Poisson model which I use on a medical data set with 329 observations. In the regression I am particularly interested in the simple Wald statistic for a single coefficient: $$t = \frac{\widehat{\beta} - \beta}{s.e.(\widehat{\beta})}$$ I was told that simply using the robust option will not help and it was sugg...
I am computing the sample correlation between two vectors of uncorrelated and uniformly distributed samples using MATLAB. More precisely, I compute $$ r_N=\frac{1}{N}\sum_{i=1}^N x_{i}\, y_{i}, $$ where $E(X)=E(Y)={\rm cov}(X,Y)=0$, and $x_{i}, y_{i}$ are drawn from a uniform distribution in $[-A/2,A/2]$. It is clear...
I have a question on calculating the threshold value or value at which the quadratic relationship turns. The formula for calculating the turn is at $x = -b/2a$, following from $ax^{2}+bx+c$. My question is this: when using the mean centered quadratic terms, do you add the mean value back to calculate the threshold turn...
I'm working on an online category learning model which uses stochastic gradient descent to fit a gaussian mixture model. The model is based on the online learning model used in Toscano & McMurray (2010). While gradient descent seems to be working fairly well to estimate the means and frequencies/mixing probabilities of...
I hope you are very well. I have a big dataset (~9 million registries) and I have 2 variables $X$=purchase amount and $Y$=frequency of purchase. I would like to know what distribution should I use for each variable and fitting its distribution with R. For example, for $X$ I'm testing with package 'mixtools' but the res...
I know that $$\hat{\beta_0}=\bar{y}-\hat{\beta_1}\bar{x}$$ and this is how far I got when I calculated the variance: \begin{align*} Var(\hat{\beta_0}) &= Var(\bar{y} - \hat{\beta_1}\bar{x}) \\ &= Var((-\bar{x})\hat{\beta_1}+\bar{y}) \\ &= Var((-\bar{x})\hat{\beta_1})+Var(\bar{y}) \\ &= (-\bar{x})^2 Var(\hat{\beta_1}) +...
How is a bifactor IRT model different from a factor analysis? How would you describe their key differences? Any references you could direct me to would be very helpful. Thank you for sharing your knowledge!
The definition of the probability density function of the continuous uniform distribution on Wikipedia is: $$ f(x) = \left\{ \begin{array}{} \frac{1}{b-a} & \text{for } a \leq x \leq b \\ 0 & \text{for } x < a \text{ or } x > b \end{array} \right. $$ As usual, $\mathbb{P}(X=x) = 0$ for an...
I have satellite data that provides radiance which I use to compute the Flux (using surface and cloud info). Now using a regression method, I can develop a mathematical model directly relating radiance and flux and can be used to predict the flux for new radiance values. Is it possible to do same using decision trees o...
Let's suppose there is a project which is expected to take a certain amount of time to complete. As certain jobs are done, we can quantifiably measure how much of the project has been completed at any time. Consider a progress bar - it starts at 0%, and is updated at some discrete time values as parts of the project a...
I imagine that the larger a coefficient on a variable is, the more ability the model has to "swing" in that dimension, providing an increased opportunity to fit noise. Although I think I've got a reasonable sense of the relationship between the variance in the model and large coefficients, I don't have as good a sense ...
I am running a CART Decision Tree, with 5 independent variables and I wonder how can I interpret the results when the same variable splits the terminal node and also splits the terminal node closest parent. For instance.. The independent variable is Income and one terminal node says x <= 11.000 "Income" and its parent ...
I'm not an expert, so forgive me if some of the terminology is a little clumsy. Happy to provide more information where required. I have two vectors of 50 paired numeric values in R. I want to perform a two-tailed randomisation or permutation test to determine whether their differences are due to chance or not. A perm...
I have a Cobb-Douglas equation I am modelling in R: $$ \ln⁡(Y) = β + β_a \ln⁡(A) + β_l \ln⁡(L) + β_f \ln⁡(F) + β_o \ln⁡(O) + u $$ Is there an easy way of testing the hypothesis about whether the betas sum to one; less than one; more than one?
I have seven numeric variables and 12 cases. All of them are measures for how well 5 different casinos are performing. The higher the variable, the better the performance. Four of the variables are: attendance figures, no. of new members, visit frequency count, and spend per head. I need to combine these four variables...
Let's say I have a logistic regression classifier. In normal batch learning, I'd have a regularizer term to prevent overfitting and keep my weights small. I'd also normalize and scale my features. In an online learning setting, I'm getting a continuous stream of data. I do a gradient descent update with each example an...
I was wondering if anyone could enlighten me on the current differences between these two functions. I found the following question: How to choose nlme or lme4 R library for mixed effects models?, but that dates from a couple of years ago. That's a lifetime in software circles. My specific questions are: Are there (st...
In a linear model (regular OLS regression) I am exploring various models of a continuous dependent variable. When adding some variables, the Akaike Information Criterion (AIC) improves (sometimes dramatically) even though the variable is not close to significant (e.g. p = .49 or even higher). One reason I can see this ...
Let $X$ be a categorical random variable with possible outcomes $o_1,...,o_n \subset [l, u]$ (real numbers with a known lower bound $l>0$ and known upper bound $u$) that occur with probability $p(X = o_i) = p_i$ for all $i$ and the probabilities sum to one, $\sum_{i=1}^n p_i = 1$. This random variable cannot be observe...
I am using R to find the value of lambda by cross-validation for ridge regression but the problem is my code as follows does not work for such a big matrix. Any help would be highly appreciated. Thanks in advance. My own work is # X<- my own dataset which has n=205 observations by 18856 variables. I = diag(18856) cv ...
I am not sure about the exact reason, why I can't use the simple OLS for switching regression. I have two outcome equations: $Y_1=\beta_0 + \beta_1'X + U_1$ $Y_0=\alpha_0 + \alpha_1'X+U_0$ and a selection equation: $D=1$ if $\gamma'Z+\epsilon>0$ and zero otherwise. Why can't I use simple OLS? The correct approach is to...
In R I created a gradient boosted random forest from 100,000 records with 10 cross validation folds using the gbm library. I want to communicate the strength and accuracy of the model, because it worked very well (far surpassing the random forest, kNN or SVM). There are plenty of strength and accuracy tests (RMS, MAE, ...
I have the following toy data: x <- structure(c(2L, 2L, 3L, 1L, 2L, 3L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 1L, 2L, 1L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 2L, 2L, 2L, 2L, 3L, 3L, 2L, 3L, 2L, 3L, 3L, 2L, 2L, 2L, 3L, 2L, ...