idx
int64
1
56k
question
stringlengths
15
155
answer
stringlengths
2
29.2k
question_cut
stringlengths
15
100
answer_cut
stringlengths
2
200
conversation
stringlengths
47
29.3k
conversation_cut
stringlengths
47
301
55,001
Help interpreting "poisson process" calculations from a paper
Yes, a moving average with large $\lambda$ will be close to Normally distributed. No, this calculation is not legitimate. Because the cumulant generating function (cgf) of a Poisson distribution of intensity $\lambda$ is $$\psi_\lambda(t) = \lambda(e^{it}-1) = i(t\lambda) + \frac{1}{2!}(it\sqrt{\lambda})^2+\lambda^{-1...
Help interpreting "poisson process" calculations from a paper
Yes, a moving average with large $\lambda$ will be close to Normally distributed. No, this calculation is not legitimate. Because the cumulant generating function (cgf) of a Poisson distribution of i
Help interpreting "poisson process" calculations from a paper Yes, a moving average with large $\lambda$ will be close to Normally distributed. No, this calculation is not legitimate. Because the cumulant generating function (cgf) of a Poisson distribution of intensity $\lambda$ is $$\psi_\lambda(t) = \lambda(e^{it}-1...
Help interpreting "poisson process" calculations from a paper Yes, a moving average with large $\lambda$ will be close to Normally distributed. No, this calculation is not legitimate. Because the cumulant generating function (cgf) of a Poisson distribution of i
55,002
Standard practice for dealing with U flagged chemistry data
Entire books have been written about this, especially Dennis Helsel's Nondetects and Data Analysis (Wiley-Interscience, 2005). Helsel has a NADA package for R, too. I will therefore confine this answer to the most important things I would explain to anyone beginning to analyze environmental data. There are more than ...
Standard practice for dealing with U flagged chemistry data
Entire books have been written about this, especially Dennis Helsel's Nondetects and Data Analysis (Wiley-Interscience, 2005). Helsel has a NADA package for R, too. I will therefore confine this answ
Standard practice for dealing with U flagged chemistry data Entire books have been written about this, especially Dennis Helsel's Nondetects and Data Analysis (Wiley-Interscience, 2005). Helsel has a NADA package for R, too. I will therefore confine this answer to the most important things I would explain to anyone be...
Standard practice for dealing with U flagged chemistry data Entire books have been written about this, especially Dennis Helsel's Nondetects and Data Analysis (Wiley-Interscience, 2005). Helsel has a NADA package for R, too. I will therefore confine this answ
55,003
Standard practice for dealing with U flagged chemistry data
We see this phenomenon in HIV modeling where CD4 and viral load are frequently below limits of detection, even though a participant is a carrier for the disease. The methods you describe are useful approaches that, while biased, are easy to describe. Let me suggest that another approach you might take is simultaneously...
Standard practice for dealing with U flagged chemistry data
We see this phenomenon in HIV modeling where CD4 and viral load are frequently below limits of detection, even though a participant is a carrier for the disease. The methods you describe are useful ap
Standard practice for dealing with U flagged chemistry data We see this phenomenon in HIV modeling where CD4 and viral load are frequently below limits of detection, even though a participant is a carrier for the disease. The methods you describe are useful approaches that, while biased, are easy to describe. Let me su...
Standard practice for dealing with U flagged chemistry data We see this phenomenon in HIV modeling where CD4 and viral load are frequently below limits of detection, even though a participant is a carrier for the disease. The methods you describe are useful ap
55,004
Calculating probability that a probability of heads lies in a given interval
If probability of heads is known If probability of heads is known, then you are not asking about confidence interval (check here and here for definition and further details), but about distribution quantiles. If you toss your coin $n$ times and observe $x \le n$ heads, then the tosses can be described by a binomial dis...
Calculating probability that a probability of heads lies in a given interval
If probability of heads is known If probability of heads is known, then you are not asking about confidence interval (check here and here for definition and further details), but about distribution qu
Calculating probability that a probability of heads lies in a given interval If probability of heads is known If probability of heads is known, then you are not asking about confidence interval (check here and here for definition and further details), but about distribution quantiles. If you toss your coin $n$ times an...
Calculating probability that a probability of heads lies in a given interval If probability of heads is known If probability of heads is known, then you are not asking about confidence interval (check here and here for definition and further details), but about distribution qu
55,005
Calculating probability that a probability of heads lies in a given interval
Assuming coin flips are independent, the number of heads has a binomial distribution with mean $np$ and variance $np(1-p)$, where $n$ is the sample size and $p$ is the true success probability. To construct the interval you first specify the confidence level (often taken to be 95%). You can compute the confidence inte...
Calculating probability that a probability of heads lies in a given interval
Assuming coin flips are independent, the number of heads has a binomial distribution with mean $np$ and variance $np(1-p)$, where $n$ is the sample size and $p$ is the true success probability. To co
Calculating probability that a probability of heads lies in a given interval Assuming coin flips are independent, the number of heads has a binomial distribution with mean $np$ and variance $np(1-p)$, where $n$ is the sample size and $p$ is the true success probability. To construct the interval you first specify the ...
Calculating probability that a probability of heads lies in a given interval Assuming coin flips are independent, the number of heads has a binomial distribution with mean $np$ and variance $np(1-p)$, where $n$ is the sample size and $p$ is the true success probability. To co
55,006
R squared always higher than 1
Your mistake doesn't come from putting the mean to zero, but from the general computation of $R^2$, which isn't the one you wrote. Using your notation we have several values: $SS_{tot} = \sum_i (y_i-\bar{y})^2$ total sum of squares $SS_{reg} = \sum_i (\hat{y}_i-\bar{y})^2$ explained sum of squares $SS_{res} = \sum_i (...
R squared always higher than 1
Your mistake doesn't come from putting the mean to zero, but from the general computation of $R^2$, which isn't the one you wrote. Using your notation we have several values: $SS_{tot} = \sum_i (y_i-
R squared always higher than 1 Your mistake doesn't come from putting the mean to zero, but from the general computation of $R^2$, which isn't the one you wrote. Using your notation we have several values: $SS_{tot} = \sum_i (y_i-\bar{y})^2$ total sum of squares $SS_{reg} = \sum_i (\hat{y}_i-\bar{y})^2$ explained sum ...
R squared always higher than 1 Your mistake doesn't come from putting the mean to zero, but from the general computation of $R^2$, which isn't the one you wrote. Using your notation we have several values: $SS_{tot} = \sum_i (y_i-
55,007
R squared always higher than 1
This is an interesting question, see this and this for two related posts. As far as I understood from the literature, and judging from the answers/comments to the above cited posts, the calculation and interpretation of the coefficient of determination and the calculation of standard errors in penalised estimation appr...
R squared always higher than 1
This is an interesting question, see this and this for two related posts. As far as I understood from the literature, and judging from the answers/comments to the above cited posts, the calculation an
R squared always higher than 1 This is an interesting question, see this and this for two related posts. As far as I understood from the literature, and judging from the answers/comments to the above cited posts, the calculation and interpretation of the coefficient of determination and the calculation of standard erro...
R squared always higher than 1 This is an interesting question, see this and this for two related posts. As far as I understood from the literature, and judging from the answers/comments to the above cited posts, the calculation an
55,008
What is the intuition of momentum term in the neural network back propagation?
Since you are asking for intuition, here's the general idea: Imagine that you are using stochastic gradient descent (SGD) to traverse the surface of the loss function. Further imagine that that surface looks like a mountain and that you are starting near the top. The surface has many small crags and lips but is clearly...
What is the intuition of momentum term in the neural network back propagation?
Since you are asking for intuition, here's the general idea: Imagine that you are using stochastic gradient descent (SGD) to traverse the surface of the loss function. Further imagine that that surfac
What is the intuition of momentum term in the neural network back propagation? Since you are asking for intuition, here's the general idea: Imagine that you are using stochastic gradient descent (SGD) to traverse the surface of the loss function. Further imagine that that surface looks like a mountain and that you are ...
What is the intuition of momentum term in the neural network back propagation? Since you are asking for intuition, here's the general idea: Imagine that you are using stochastic gradient descent (SGD) to traverse the surface of the loss function. Further imagine that that surfac
55,009
What is the intuition of momentum term in the neural network back propagation?
Firstly, let's pretend we have just started training so that: \begin{equation} n = 0 \end{equation} and \begin{equation} \omega_{kj}(0) = \alpha\delta_jy_k \end{equation} because this is the first time step. If we go one training step further to \begin{equation} n = 1 \end{equation} then: \begin{equation} \omega_{kj}(1...
What is the intuition of momentum term in the neural network back propagation?
Firstly, let's pretend we have just started training so that: \begin{equation} n = 0 \end{equation} and \begin{equation} \omega_{kj}(0) = \alpha\delta_jy_k \end{equation} because this is the first tim
What is the intuition of momentum term in the neural network back propagation? Firstly, let's pretend we have just started training so that: \begin{equation} n = 0 \end{equation} and \begin{equation} \omega_{kj}(0) = \alpha\delta_jy_k \end{equation} because this is the first time step. If we go one training step furthe...
What is the intuition of momentum term in the neural network back propagation? Firstly, let's pretend we have just started training so that: \begin{equation} n = 0 \end{equation} and \begin{equation} \omega_{kj}(0) = \alpha\delta_jy_k \end{equation} because this is the first tim
55,010
Time Series and XGBoost
It is likely that your features have time biases. Assume you want to predict month and year from your data. You would see very good performance during CV as you have enough data points at each month. However you can not predict the future(April 2016 to June 2016) very well using your predictor. Another example is that ...
Time Series and XGBoost
It is likely that your features have time biases. Assume you want to predict month and year from your data. You would see very good performance during CV as you have enough data points at each month.
Time Series and XGBoost It is likely that your features have time biases. Assume you want to predict month and year from your data. You would see very good performance during CV as you have enough data points at each month. However you can not predict the future(April 2016 to June 2016) very well using your predictor. ...
Time Series and XGBoost It is likely that your features have time biases. Assume you want to predict month and year from your data. You would see very good performance during CV as you have enough data points at each month.
55,011
Time Series and XGBoost
First, if there is a trend in time series, then tree-based model maybe not the good choice (because of tree model can't extrapolate, can't predict value bigger or smaller than the value in the training set), or you can remove the trend first, then using the xgboost to predict the residuals of linear models. Second, as ...
Time Series and XGBoost
First, if there is a trend in time series, then tree-based model maybe not the good choice (because of tree model can't extrapolate, can't predict value bigger or smaller than the value in the trainin
Time Series and XGBoost First, if there is a trend in time series, then tree-based model maybe not the good choice (because of tree model can't extrapolate, can't predict value bigger or smaller than the value in the training set), or you can remove the trend first, then using the xgboost to predict the residuals of li...
Time Series and XGBoost First, if there is a trend in time series, then tree-based model maybe not the good choice (because of tree model can't extrapolate, can't predict value bigger or smaller than the value in the trainin
55,012
Slope and intercept of the decision boundary from a logistic regression model
This is actually straightforward. We think of statistical models specifying a conditional response distribution, which is stochastic, but once you are working with the fitted model, it is just a deterministic function. In this case, a logistic regression model specifies the conditional parameter $\pi$ that governs th...
Slope and intercept of the decision boundary from a logistic regression model
This is actually straightforward. We think of statistical models specifying a conditional response distribution, which is stochastic, but once you are working with the fitted model, it is just a dete
Slope and intercept of the decision boundary from a logistic regression model This is actually straightforward. We think of statistical models specifying a conditional response distribution, which is stochastic, but once you are working with the fitted model, it is just a deterministic function. In this case, a logis...
Slope and intercept of the decision boundary from a logistic regression model This is actually straightforward. We think of statistical models specifying a conditional response distribution, which is stochastic, but once you are working with the fitted model, it is just a dete
55,013
Slope and intercept of the decision boundary from a logistic regression model
It sounds simply like your model was simply projected to consider a bivariate relationship between a single regressor and your outcome. The additive assumptions of the GLM ensure that the conditional mean relation between a first regressor and the outcome does not vary for other levels of the second regressor. The seco...
Slope and intercept of the decision boundary from a logistic regression model
It sounds simply like your model was simply projected to consider a bivariate relationship between a single regressor and your outcome. The additive assumptions of the GLM ensure that the conditional
Slope and intercept of the decision boundary from a logistic regression model It sounds simply like your model was simply projected to consider a bivariate relationship between a single regressor and your outcome. The additive assumptions of the GLM ensure that the conditional mean relation between a first regressor an...
Slope and intercept of the decision boundary from a logistic regression model It sounds simply like your model was simply projected to consider a bivariate relationship between a single regressor and your outcome. The additive assumptions of the GLM ensure that the conditional
55,014
Confidence Interval from bootstrap
There are at least 4 or 5 types of Bootstrap confidence intervals (BCa, bootstrap-t, ABC, and calibration). These are thoroughly described here: Bootstrap Confidence Intervals. Thomas J. DiCiccio and Bradley Efron And they are all implemented in the 'boot' R package.
Confidence Interval from bootstrap
There are at least 4 or 5 types of Bootstrap confidence intervals (BCa, bootstrap-t, ABC, and calibration). These are thoroughly described here: Bootstrap Confidence Intervals. Thomas J. DiCiccio and
Confidence Interval from bootstrap There are at least 4 or 5 types of Bootstrap confidence intervals (BCa, bootstrap-t, ABC, and calibration). These are thoroughly described here: Bootstrap Confidence Intervals. Thomas J. DiCiccio and Bradley Efron And they are all implemented in the 'boot' R package.
Confidence Interval from bootstrap There are at least 4 or 5 types of Bootstrap confidence intervals (BCa, bootstrap-t, ABC, and calibration). These are thoroughly described here: Bootstrap Confidence Intervals. Thomas J. DiCiccio and
55,015
Confidence Interval from bootstrap
Some ideas I have read about in Rand R. Wilcox - Fundamentals of Modern Statistical Methods, which by the way, it is a really nice book to read in general. Approach 1 which is called percentile bootstrap works well only if you have a pretty number of observations and it covers well the whole interval of interest. App...
Confidence Interval from bootstrap
Some ideas I have read about in Rand R. Wilcox - Fundamentals of Modern Statistical Methods, which by the way, it is a really nice book to read in general. Approach 1 which is called percentile boots
Confidence Interval from bootstrap Some ideas I have read about in Rand R. Wilcox - Fundamentals of Modern Statistical Methods, which by the way, it is a really nice book to read in general. Approach 1 which is called percentile bootstrap works well only if you have a pretty number of observations and it covers well t...
Confidence Interval from bootstrap Some ideas I have read about in Rand R. Wilcox - Fundamentals of Modern Statistical Methods, which by the way, it is a really nice book to read in general. Approach 1 which is called percentile boots
55,016
When using the likelihood function, where does the indicator function come from?
Most families of distributions $f_\theta$ have a fixed support, $$\text{supp}(f_\theta)=\{x\in\mathcal{X};\ f_\theta(x)>0\}$$ like the Normal or Binomial distributions, but some have a parameter dependent support, like uniforms $\text{U}(0,\theta)$ or $\text{U}(-\theta,\theta)$. For such families, it is important to ke...
When using the likelihood function, where does the indicator function come from?
Most families of distributions $f_\theta$ have a fixed support, $$\text{supp}(f_\theta)=\{x\in\mathcal{X};\ f_\theta(x)>0\}$$ like the Normal or Binomial distributions, but some have a parameter depen
When using the likelihood function, where does the indicator function come from? Most families of distributions $f_\theta$ have a fixed support, $$\text{supp}(f_\theta)=\{x\in\mathcal{X};\ f_\theta(x)>0\}$$ like the Normal or Binomial distributions, but some have a parameter dependent support, like uniforms $\text{U}(0...
When using the likelihood function, where does the indicator function come from? Most families of distributions $f_\theta$ have a fixed support, $$\text{supp}(f_\theta)=\{x\in\mathcal{X};\ f_\theta(x)>0\}$$ like the Normal or Binomial distributions, but some have a parameter depen
55,017
Is there a corresponding bias-variance decomposition of MSE for vectors?
Simply note that $$|| \widehat{\mu} - \mu ||^2 = \sum\limits_{i = 1}^{n} (\widehat{\mu}_{i} - \mu_{i})^2$$ Then, the answer is given by the decomposition you gave earlier: $$ \mathbb{E}[(\widehat{\mu}_{i} - \mu_{i})^2] = Var[\widehat{\mu}_{i}] + [Bias(\widehat{\mu}_{i}, \mu_{i} )]^2 $$ Summing all up, we get $$ \mathbb...
Is there a corresponding bias-variance decomposition of MSE for vectors?
Simply note that $$|| \widehat{\mu} - \mu ||^2 = \sum\limits_{i = 1}^{n} (\widehat{\mu}_{i} - \mu_{i})^2$$ Then, the answer is given by the decomposition you gave earlier: $$ \mathbb{E}[(\widehat{\mu}
Is there a corresponding bias-variance decomposition of MSE for vectors? Simply note that $$|| \widehat{\mu} - \mu ||^2 = \sum\limits_{i = 1}^{n} (\widehat{\mu}_{i} - \mu_{i})^2$$ Then, the answer is given by the decomposition you gave earlier: $$ \mathbb{E}[(\widehat{\mu}_{i} - \mu_{i})^2] = Var[\widehat{\mu}_{i}] + [...
Is there a corresponding bias-variance decomposition of MSE for vectors? Simply note that $$|| \widehat{\mu} - \mu ||^2 = \sum\limits_{i = 1}^{n} (\widehat{\mu}_{i} - \mu_{i})^2$$ Then, the answer is given by the decomposition you gave earlier: $$ \mathbb{E}[(\widehat{\mu}
55,018
How do I fit a constrained regression in R so all coefficients are positive and above 0 [duplicate]
First of all you should add set.seed(1) (or any other seed) at the start of your code, so that it's reproducible. Coming to your question: From ?solve.QP: meq the first meq constraints are treated as equality constraints, all further as inequality constraints (defaults to 0). Thus, when you set meq=1, you're tell...
How do I fit a constrained regression in R so all coefficients are positive and above 0 [duplicate]
First of all you should add set.seed(1) (or any other seed) at the start of your code, so that it's reproducible. Coming to your question: From ?solve.QP: meq the first meq constraints are treate
How do I fit a constrained regression in R so all coefficients are positive and above 0 [duplicate] First of all you should add set.seed(1) (or any other seed) at the start of your code, so that it's reproducible. Coming to your question: From ?solve.QP: meq the first meq constraints are treated as equality constr...
How do I fit a constrained regression in R so all coefficients are positive and above 0 [duplicate] First of all you should add set.seed(1) (or any other seed) at the start of your code, so that it's reproducible. Coming to your question: From ?solve.QP: meq the first meq constraints are treate
55,019
What academic paper introduces CNNs in deep learning?
Two recent papers come to mind: Lecun, Bengio and Hinton, Deep Learning, http://www.cs.toronto.edu/~hinton/absps/NatureDeepReview.pdf Schmidhuber, Deep Learning in Neural Networks: An Overview, http://people.idsia.ch/~juergen/DeepLearning2July2014.pdf
What academic paper introduces CNNs in deep learning?
Two recent papers come to mind: Lecun, Bengio and Hinton, Deep Learning, http://www.cs.toronto.edu/~hinton/absps/NatureDeepReview.pdf Schmidhuber, Deep Learning in Neural Networks: An Overview, http:/
What academic paper introduces CNNs in deep learning? Two recent papers come to mind: Lecun, Bengio and Hinton, Deep Learning, http://www.cs.toronto.edu/~hinton/absps/NatureDeepReview.pdf Schmidhuber, Deep Learning in Neural Networks: An Overview, http://people.idsia.ch/~juergen/DeepLearning2July2014.pdf
What academic paper introduces CNNs in deep learning? Two recent papers come to mind: Lecun, Bengio and Hinton, Deep Learning, http://www.cs.toronto.edu/~hinton/absps/NatureDeepReview.pdf Schmidhuber, Deep Learning in Neural Networks: An Overview, http:/
55,020
What academic paper introduces CNNs in deep learning?
As mentioned in another answer, the recent Deep Learning Review in Nature has some good discussion of this. I am not in this field, so cannot say how much this is a balanced review vs. just the authors' perspective. However one of the authors, Yann LeCun, seems to be widely acknowledged as essentially the "father of co...
What academic paper introduces CNNs in deep learning?
As mentioned in another answer, the recent Deep Learning Review in Nature has some good discussion of this. I am not in this field, so cannot say how much this is a balanced review vs. just the author
What academic paper introduces CNNs in deep learning? As mentioned in another answer, the recent Deep Learning Review in Nature has some good discussion of this. I am not in this field, so cannot say how much this is a balanced review vs. just the authors' perspective. However one of the authors, Yann LeCun, seems to b...
What academic paper introduces CNNs in deep learning? As mentioned in another answer, the recent Deep Learning Review in Nature has some good discussion of this. I am not in this field, so cannot say how much this is a balanced review vs. just the author
55,021
Distribution of quadratic equation roots where coefficients are generated uniformly
There are two steps in any question of this nature: (1) find a useful way to characterize the event and (2) compute the probability of this event (in general, by integrating a probability density over it). When the probability is uniform, the integral is proportional to the area of the event. I wish to emphasize the t...
Distribution of quadratic equation roots where coefficients are generated uniformly
There are two steps in any question of this nature: (1) find a useful way to characterize the event and (2) compute the probability of this event (in general, by integrating a probability density over
Distribution of quadratic equation roots where coefficients are generated uniformly There are two steps in any question of this nature: (1) find a useful way to characterize the event and (2) compute the probability of this event (in general, by integrating a probability density over it). When the probability is unifo...
Distribution of quadratic equation roots where coefficients are generated uniformly There are two steps in any question of this nature: (1) find a useful way to characterize the event and (2) compute the probability of this event (in general, by integrating a probability density over
55,022
Distribution of quadratic equation roots where coefficients are generated uniformly
It's possible the answer is a bit confusing because the question starts with one parabola (involving $p, q, x$), and the solution uses a different parabola (which should involve $p, q$, but the answer switches the variables to $x, y$, even though the second use of $x$ is unrelated to the first). If the quadratic equati...
Distribution of quadratic equation roots where coefficients are generated uniformly
It's possible the answer is a bit confusing because the question starts with one parabola (involving $p, q, x$), and the solution uses a different parabola (which should involve $p, q$, but the answer
Distribution of quadratic equation roots where coefficients are generated uniformly It's possible the answer is a bit confusing because the question starts with one parabola (involving $p, q, x$), and the solution uses a different parabola (which should involve $p, q$, but the answer switches the variables to $x, y$, e...
Distribution of quadratic equation roots where coefficients are generated uniformly It's possible the answer is a bit confusing because the question starts with one parabola (involving $p, q, x$), and the solution uses a different parabola (which should involve $p, q$, but the answer
55,023
Distribution of quadratic equation roots where coefficients are generated uniformly
OP Looks like I found you again. The incorrect solution snapshot above is mine, and I apologize. Apparently I do not know integration limits and the quadratic equation, but that's besides the point. Here's the corrections.
Distribution of quadratic equation roots where coefficients are generated uniformly
OP Looks like I found you again. The incorrect solution snapshot above is mine, and I apologize. Apparently I do not know integration limits and the quadratic equation, but that's besides the point. H
Distribution of quadratic equation roots where coefficients are generated uniformly OP Looks like I found you again. The incorrect solution snapshot above is mine, and I apologize. Apparently I do not know integration limits and the quadratic equation, but that's besides the point. Here's the corrections.
Distribution of quadratic equation roots where coefficients are generated uniformly OP Looks like I found you again. The incorrect solution snapshot above is mine, and I apologize. Apparently I do not know integration limits and the quadratic equation, but that's besides the point. H
55,024
Does the null hypothesis for a t-test have to be 0?
No, it doesn't have to be $0$. You can have your null that the difference is $5$, for example, or some other specific number (cf., here). What you can't have is a null that the difference is $\neq 0$. (For more on that distinction, see my answer here: Why do statisticians say a non-significant result means “you can'...
Does the null hypothesis for a t-test have to be 0?
No, it doesn't have to be $0$. You can have your null that the difference is $5$, for example, or some other specific number (cf., here). What you can't have is a null that the difference is $\neq 0
Does the null hypothesis for a t-test have to be 0? No, it doesn't have to be $0$. You can have your null that the difference is $5$, for example, or some other specific number (cf., here). What you can't have is a null that the difference is $\neq 0$. (For more on that distinction, see my answer here: Why do statis...
Does the null hypothesis for a t-test have to be 0? No, it doesn't have to be $0$. You can have your null that the difference is $5$, for example, or some other specific number (cf., here). What you can't have is a null that the difference is $\neq 0
55,025
Does the null hypothesis for a t-test have to be 0?
It should be some value you specify before you have any data ... but it doesn't have to be zero. For example, imagine someone makes a claim that their tutoring program improves mathematics test scores by 5 (out of 100). You could make that 5 improvement your null value in a paired test and then do an experiment where ...
Does the null hypothesis for a t-test have to be 0?
It should be some value you specify before you have any data ... but it doesn't have to be zero. For example, imagine someone makes a claim that their tutoring program improves mathematics test score
Does the null hypothesis for a t-test have to be 0? It should be some value you specify before you have any data ... but it doesn't have to be zero. For example, imagine someone makes a claim that their tutoring program improves mathematics test scores by 5 (out of 100). You could make that 5 improvement your null val...
Does the null hypothesis for a t-test have to be 0? It should be some value you specify before you have any data ... but it doesn't have to be zero. For example, imagine someone makes a claim that their tutoring program improves mathematics test score
55,026
measure graph complexity
Common graph measures include : Connectivity : is the graph connected - i.e. can you reach any node from any other node, or can you break the graph down into "islands" or regions that are unreachable from one another? Tree-test : does the graph conform to a tree-shape (i.e. can you reach any node from any other node v...
measure graph complexity
Common graph measures include : Connectivity : is the graph connected - i.e. can you reach any node from any other node, or can you break the graph down into "islands" or regions that are unreachable
measure graph complexity Common graph measures include : Connectivity : is the graph connected - i.e. can you reach any node from any other node, or can you break the graph down into "islands" or regions that are unreachable from one another? Tree-test : does the graph conform to a tree-shape (i.e. can you reach any n...
measure graph complexity Common graph measures include : Connectivity : is the graph connected - i.e. can you reach any node from any other node, or can you break the graph down into "islands" or regions that are unreachable
55,027
What is the distribution of the maximum of a set of random variables? [duplicate]
The general solution is exactly the same as a particular solution. $$P(\max_i X_i \leq t) = \prod_i P(X_i \leq t) = \prod_i F_{X_i}(t).$$
What is the distribution of the maximum of a set of random variables? [duplicate]
The general solution is exactly the same as a particular solution. $$P(\max_i X_i \leq t) = \prod_i P(X_i \leq t) = \prod_i F_{X_i}(t).$$
What is the distribution of the maximum of a set of random variables? [duplicate] The general solution is exactly the same as a particular solution. $$P(\max_i X_i \leq t) = \prod_i P(X_i \leq t) = \prod_i F_{X_i}(t).$$
What is the distribution of the maximum of a set of random variables? [duplicate] The general solution is exactly the same as a particular solution. $$P(\max_i X_i \leq t) = \prod_i P(X_i \leq t) = \prod_i F_{X_i}(t).$$
55,028
Possible to use draws from two distributions to get draw from distribution with density their product?
From a pure simulation point of view (Warning: link to my book), aiming at simulating from a product $f\times g$ of two (positive) functions such that $fg$ is integrable over the proper region suggests some specific methods: Sampling-importance-resampling: to apply when samples from both $f$ and $g$ can be produced an...
Possible to use draws from two distributions to get draw from distribution with density their produc
From a pure simulation point of view (Warning: link to my book), aiming at simulating from a product $f\times g$ of two (positive) functions such that $fg$ is integrable over the proper region suggest
Possible to use draws from two distributions to get draw from distribution with density their product? From a pure simulation point of view (Warning: link to my book), aiming at simulating from a product $f\times g$ of two (positive) functions such that $fg$ is integrable over the proper region suggests some specific m...
Possible to use draws from two distributions to get draw from distribution with density their produc From a pure simulation point of view (Warning: link to my book), aiming at simulating from a product $f\times g$ of two (positive) functions such that $fg$ is integrable over the proper region suggest
55,029
How to derive the second moment of the Chi-Square distribution with the MGF?
You made a mistake while taking the derivatives. $$M_X'(t) = \dfrac{d}{dt} (1 - 2t)^{-r/2} = \dfrac{2r}{2} (1-2t)^{-r/2 -1} = r(1-2t)^{-\frac{r+2}{2} }.$$ The same mistake you made in taking the second derivative.
How to derive the second moment of the Chi-Square distribution with the MGF?
You made a mistake while taking the derivatives. $$M_X'(t) = \dfrac{d}{dt} (1 - 2t)^{-r/2} = \dfrac{2r}{2} (1-2t)^{-r/2 -1} = r(1-2t)^{-\frac{r+2}{2} }.$$ The same mistake you made in taking the secon
How to derive the second moment of the Chi-Square distribution with the MGF? You made a mistake while taking the derivatives. $$M_X'(t) = \dfrac{d}{dt} (1 - 2t)^{-r/2} = \dfrac{2r}{2} (1-2t)^{-r/2 -1} = r(1-2t)^{-\frac{r+2}{2} }.$$ The same mistake you made in taking the second derivative.
How to derive the second moment of the Chi-Square distribution with the MGF? You made a mistake while taking the derivatives. $$M_X'(t) = \dfrac{d}{dt} (1 - 2t)^{-r/2} = \dfrac{2r}{2} (1-2t)^{-r/2 -1} = r(1-2t)^{-\frac{r+2}{2} }.$$ The same mistake you made in taking the secon
55,030
How to derive the second moment of the Chi-Square distribution with the MGF?
For the record, it would be more typical to use $\nu$ as the degrees of freedom, and $r$ as the moment number. Then the Chi-squared density function is $$\begin{cases} \frac{2^{-\frac{\nu }{2}} e^{-\frac{x}{2}} x^{\frac{\nu }{2}-1}}{\Gamma \left(\frac{\nu }{2}\right)} & x>0 \\ 0 & \text{True} \end{cases}$$ The momen...
How to derive the second moment of the Chi-Square distribution with the MGF?
For the record, it would be more typical to use $\nu$ as the degrees of freedom, and $r$ as the moment number. Then the Chi-squared density function is $$\begin{cases} \frac{2^{-\frac{\nu }{2}} e^{-\
How to derive the second moment of the Chi-Square distribution with the MGF? For the record, it would be more typical to use $\nu$ as the degrees of freedom, and $r$ as the moment number. Then the Chi-squared density function is $$\begin{cases} \frac{2^{-\frac{\nu }{2}} e^{-\frac{x}{2}} x^{\frac{\nu }{2}-1}}{\Gamma \l...
How to derive the second moment of the Chi-Square distribution with the MGF? For the record, it would be more typical to use $\nu$ as the degrees of freedom, and $r$ as the moment number. Then the Chi-squared density function is $$\begin{cases} \frac{2^{-\frac{\nu }{2}} e^{-\
55,031
What does Jim Simons mean by "never override the computer"?
Simons is talking about his company, which uses quantitative methods to automate financial trades of various kinds. "Overriding the computer" means making a trade other than what the computers are currently programmed to make, or preventing a computer-scheduled trade. The reason, Simons goes on to say, is that statisti...
What does Jim Simons mean by "never override the computer"?
Simons is talking about his company, which uses quantitative methods to automate financial trades of various kinds. "Overriding the computer" means making a trade other than what the computers are cur
What does Jim Simons mean by "never override the computer"? Simons is talking about his company, which uses quantitative methods to automate financial trades of various kinds. "Overriding the computer" means making a trade other than what the computers are currently programmed to make, or preventing a computer-schedule...
What does Jim Simons mean by "never override the computer"? Simons is talking about his company, which uses quantitative methods to automate financial trades of various kinds. "Overriding the computer" means making a trade other than what the computers are cur
55,032
Smoother matrix from smooth.spline
After many hours of exploration, here is what I found: Because smooth.spline algorithm chooses spar instead of lambda, it is only possible to (sort of) fix spar. However, lambda is a function of spar and another variable matrix. So fixing spar does not fix lambda necessarily. I have not found an easy way to extract the...
Smoother matrix from smooth.spline
After many hours of exploration, here is what I found: Because smooth.spline algorithm chooses spar instead of lambda, it is only possible to (sort of) fix spar. However, lambda is a function of spar
Smoother matrix from smooth.spline After many hours of exploration, here is what I found: Because smooth.spline algorithm chooses spar instead of lambda, it is only possible to (sort of) fix spar. However, lambda is a function of spar and another variable matrix. So fixing spar does not fix lambda necessarily. I have n...
Smoother matrix from smooth.spline After many hours of exploration, here is what I found: Because smooth.spline algorithm chooses spar instead of lambda, it is only possible to (sort of) fix spar. However, lambda is a function of spar
55,033
Smoother matrix from smooth.spline
The above answers only approximate the smoothing matrix. Here is a solution that will get you the exact smoothing matrix from the r function smooth.spline(). The key is to recognize that the smoothing matrix is only a function of the values of $x$ and the penalization parameter $\lambda$, allowing us to smooth a vector...
Smoother matrix from smooth.spline
The above answers only approximate the smoothing matrix. Here is a solution that will get you the exact smoothing matrix from the r function smooth.spline(). The key is to recognize that the smoothing
Smoother matrix from smooth.spline The above answers only approximate the smoothing matrix. Here is a solution that will get you the exact smoothing matrix from the r function smooth.spline(). The key is to recognize that the smoothing matrix is only a function of the values of $x$ and the penalization parameter $\lamb...
Smoother matrix from smooth.spline The above answers only approximate the smoothing matrix. Here is a solution that will get you the exact smoothing matrix from the r function smooth.spline(). The key is to recognize that the smoothing
55,034
Smoother matrix from smooth.spline
The accepted answer isn't correct here - smooth.matrix is working just fine. The only reason fromsm and fromfit aren't the same in the above example is because of misplaced parentheses. Replace fromsm <- sm%*%(bone$spnbmd[order(bone$age)]) with fromsm <- (sm%*%bone$spnbmd)[order(bone$age)] and they are the same.
Smoother matrix from smooth.spline
The accepted answer isn't correct here - smooth.matrix is working just fine. The only reason fromsm and fromfit aren't the same in the above example is because of misplaced parentheses. Replace froms
Smoother matrix from smooth.spline The accepted answer isn't correct here - smooth.matrix is working just fine. The only reason fromsm and fromfit aren't the same in the above example is because of misplaced parentheses. Replace fromsm <- sm%*%(bone$spnbmd[order(bone$age)]) with fromsm <- (sm%*%bone$spnbmd)[order(bone...
Smoother matrix from smooth.spline The accepted answer isn't correct here - smooth.matrix is working just fine. The only reason fromsm and fromfit aren't the same in the above example is because of misplaced parentheses. Replace froms
55,035
What's the official name of a 1 to 1 line plot?
The official name of the line is 'identity line' or 'line of equality'. And if you are comparing measured data with predicted data, or two different models, you should standardize the axis. The starting and ending point of both axes should be the same. You can also plot the trend line in the scatter plot (measured ~ pr...
What's the official name of a 1 to 1 line plot?
The official name of the line is 'identity line' or 'line of equality'. And if you are comparing measured data with predicted data, or two different models, you should standardize the axis. The starti
What's the official name of a 1 to 1 line plot? The official name of the line is 'identity line' or 'line of equality'. And if you are comparing measured data with predicted data, or two different models, you should standardize the axis. The starting and ending point of both axes should be the same. You can also plot t...
What's the official name of a 1 to 1 line plot? The official name of the line is 'identity line' or 'line of equality'. And if you are comparing measured data with predicted data, or two different models, you should standardize the axis. The starti
55,036
What's the official name of a 1 to 1 line plot?
Based on your comment, I think what you are ultimately after is to assess agreement (see Wikipedia, or John Uebersax's website). I don't think there is a name for the plot you have in mind. I would just call it a scatterplot with a 1:1 reference line plotted. I think that's probably fine to do. I would not standard...
What's the official name of a 1 to 1 line plot?
Based on your comment, I think what you are ultimately after is to assess agreement (see Wikipedia, or John Uebersax's website). I don't think there is a name for the plot you have in mind. I would
What's the official name of a 1 to 1 line plot? Based on your comment, I think what you are ultimately after is to assess agreement (see Wikipedia, or John Uebersax's website). I don't think there is a name for the plot you have in mind. I would just call it a scatterplot with a 1:1 reference line plotted. I think t...
What's the official name of a 1 to 1 line plot? Based on your comment, I think what you are ultimately after is to assess agreement (see Wikipedia, or John Uebersax's website). I don't think there is a name for the plot you have in mind. I would
55,037
Does uncorrelation imply independence for marginally Gaussian random variables?
If $X = (X_1,\ldots, X_n)$ are jointly normal, too, then yes. Otherwise, no. In this case $\Sigma = \text{diag}(\sigma_1^2,\ldots, \sigma_2^2)$ and $\mu = (\mu_1,\ldots,\mu_n)'$ \begin{align*}f_X(x) &= (2\pi)^{-\frac{n}{2}}|\Sigma|^{-\frac{1}{2}}\exp\left[-\frac{1}{2}(x-\mu)'\Sigma^{-1}(x-\mu) \right] \\ &= (2\pi)^{-\f...
Does uncorrelation imply independence for marginally Gaussian random variables?
If $X = (X_1,\ldots, X_n)$ are jointly normal, too, then yes. Otherwise, no. In this case $\Sigma = \text{diag}(\sigma_1^2,\ldots, \sigma_2^2)$ and $\mu = (\mu_1,\ldots,\mu_n)'$ \begin{align*}f_X(x) &
Does uncorrelation imply independence for marginally Gaussian random variables? If $X = (X_1,\ldots, X_n)$ are jointly normal, too, then yes. Otherwise, no. In this case $\Sigma = \text{diag}(\sigma_1^2,\ldots, \sigma_2^2)$ and $\mu = (\mu_1,\ldots,\mu_n)'$ \begin{align*}f_X(x) &= (2\pi)^{-\frac{n}{2}}|\Sigma|^{-\frac{...
Does uncorrelation imply independence for marginally Gaussian random variables? If $X = (X_1,\ldots, X_n)$ are jointly normal, too, then yes. Otherwise, no. In this case $\Sigma = \text{diag}(\sigma_1^2,\ldots, \sigma_2^2)$ and $\mu = (\mu_1,\ldots,\mu_n)'$ \begin{align*}f_X(x) &
55,038
What is the normal distribution when standard deviation is zero?
When standard deviation is zero, your Gaussian (normal) PDF turns into Dirac delta function. You can't simply plug zero standard deviation into the conventional expression. For instance, if the PDF is plugged into some kind of numerical integration, this won't work. You have to modify the integrals. In the example belo...
What is the normal distribution when standard deviation is zero?
When standard deviation is zero, your Gaussian (normal) PDF turns into Dirac delta function. You can't simply plug zero standard deviation into the conventional expression. For instance, if the PDF is
What is the normal distribution when standard deviation is zero? When standard deviation is zero, your Gaussian (normal) PDF turns into Dirac delta function. You can't simply plug zero standard deviation into the conventional expression. For instance, if the PDF is plugged into some kind of numerical integration, this ...
What is the normal distribution when standard deviation is zero? When standard deviation is zero, your Gaussian (normal) PDF turns into Dirac delta function. You can't simply plug zero standard deviation into the conventional expression. For instance, if the PDF is
55,039
What is the normal distribution when standard deviation is zero?
This is a question in the Statistics textbook by Hogg and Craig! The authors give a hint: Look at the moment generating function of the normal and plug in sigma = 0. So before going to the answer, let's remember why this works - moment generating functions are unique. The moment generating function of the normal, N(...
What is the normal distribution when standard deviation is zero?
This is a question in the Statistics textbook by Hogg and Craig! The authors give a hint: Look at the moment generating function of the normal and plug in sigma = 0. So before going to the answer, l
What is the normal distribution when standard deviation is zero? This is a question in the Statistics textbook by Hogg and Craig! The authors give a hint: Look at the moment generating function of the normal and plug in sigma = 0. So before going to the answer, let's remember why this works - moment generating functi...
What is the normal distribution when standard deviation is zero? This is a question in the Statistics textbook by Hogg and Craig! The authors give a hint: Look at the moment generating function of the normal and plug in sigma = 0. So before going to the answer, l
55,040
Object of type 'closure' is not subsettable [closed]
You have assigned an object to the name dt. Unfortunately dt is also the name of a built in R function. Because of R's scoping rules (though, as @ssdecontrol points out in the comments, it's not clear why), the dt on the right hand side of your last line resolves to this function, not the data table you created. A fu...
Object of type 'closure' is not subsettable [closed]
You have assigned an object to the name dt. Unfortunately dt is also the name of a built in R function. Because of R's scoping rules (though, as @ssdecontrol points out in the comments, it's not clea
Object of type 'closure' is not subsettable [closed] You have assigned an object to the name dt. Unfortunately dt is also the name of a built in R function. Because of R's scoping rules (though, as @ssdecontrol points out in the comments, it's not clear why), the dt on the right hand side of your last line resolves to...
Object of type 'closure' is not subsettable [closed] You have assigned an object to the name dt. Unfortunately dt is also the name of a built in R function. Because of R's scoping rules (though, as @ssdecontrol points out in the comments, it's not clea
55,041
Clustering: k-means alternatives when its assumptions do not hold
In the answers to How to understand the drawbacks of K-means we have already discussed drawbacks of k-means in detail. Some of them may appear easy to counter for toy examples (e.g. by undoing scaling for distorted data sets) but real data will be much more complex, and global normalization may not be enough, unfortuna...
Clustering: k-means alternatives when its assumptions do not hold
In the answers to How to understand the drawbacks of K-means we have already discussed drawbacks of k-means in detail. Some of them may appear easy to counter for toy examples (e.g. by undoing scaling
Clustering: k-means alternatives when its assumptions do not hold In the answers to How to understand the drawbacks of K-means we have already discussed drawbacks of k-means in detail. Some of them may appear easy to counter for toy examples (e.g. by undoing scaling for distorted data sets) but real data will be much m...
Clustering: k-means alternatives when its assumptions do not hold In the answers to How to understand the drawbacks of K-means we have already discussed drawbacks of k-means in detail. Some of them may appear easy to counter for toy examples (e.g. by undoing scaling
55,042
How does one decide on whether to use a GLMM versus an LME? And how do you select the random/fixed effects?
If you have count data as the response variable then you should be using a glmm. A poisson model is appropriate so long as it is not over-dispersed or zero-inflated, in which case you will need to consider other glmms. If I understood the description correctly then have 3 repeated measures in 2 sites where each site ha...
How does one decide on whether to use a GLMM versus an LME? And how do you select the random/fixed e
If you have count data as the response variable then you should be using a glmm. A poisson model is appropriate so long as it is not over-dispersed or zero-inflated, in which case you will need to con
How does one decide on whether to use a GLMM versus an LME? And how do you select the random/fixed effects? If you have count data as the response variable then you should be using a glmm. A poisson model is appropriate so long as it is not over-dispersed or zero-inflated, in which case you will need to consider other ...
How does one decide on whether to use a GLMM versus an LME? And how do you select the random/fixed e If you have count data as the response variable then you should be using a glmm. A poisson model is appropriate so long as it is not over-dispersed or zero-inflated, in which case you will need to con
55,043
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV?
The equivariance to monotone transformations property that implies $Q_q(y \vert x)=\exp \{Q_q(\ln y|x )\}$ is exact only if the conditional quantile function is correctly specified. This is unlikely to be the case in practice, and is not the case in your simulation, since $\exp \{x+\varepsilon\} \ne x + \varepsilon$. ...
Why are the predictions of a quantile regression model changed by an increasing transformation of th
The equivariance to monotone transformations property that implies $Q_q(y \vert x)=\exp \{Q_q(\ln y|x )\}$ is exact only if the conditional quantile function is correctly specified. This is unlikely t
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV? The equivariance to monotone transformations property that implies $Q_q(y \vert x)=\exp \{Q_q(\ln y|x )\}$ is exact only if the conditional quantile function is correctly specified. This is unlikely to be the case ...
Why are the predictions of a quantile regression model changed by an increasing transformation of th The equivariance to monotone transformations property that implies $Q_q(y \vert x)=\exp \{Q_q(\ln y|x )\}$ is exact only if the conditional quantile function is correctly specified. This is unlikely t
55,044
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV?
This isn't a complete answer, but it may help. The covariate in your model may be a red herring, the issue is reproducible with an intercept only model set.seed(1) y = runif(100, 0, 1) # Need to keep it positive for the log. m = rq(y ~ 1, tau = .5) p1 = predict(m) m2 = rq(log(y) ~ 1, tau = .5) p2 = exp(predict(m2))...
Why are the predictions of a quantile regression model changed by an increasing transformation of th
This isn't a complete answer, but it may help. The covariate in your model may be a red herring, the issue is reproducible with an intercept only model set.seed(1) y = runif(100, 0, 1) # Need to kee
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV? This isn't a complete answer, but it may help. The covariate in your model may be a red herring, the issue is reproducible with an intercept only model set.seed(1) y = runif(100, 0, 1) # Need to keep it positive ...
Why are the predictions of a quantile regression model changed by an increasing transformation of th This isn't a complete answer, but it may help. The covariate in your model may be a red herring, the issue is reproducible with an intercept only model set.seed(1) y = runif(100, 0, 1) # Need to kee
55,045
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV?
The fitted values are calculated by substituting in the vector values of the independent variable to the coefficient estimates (in this case of the median). $y = mx +c$. There is a direct linear relationship between the original (m) and log (m2) predictions (ie. same x with different slope and intercept). Here's a c...
Why are the predictions of a quantile regression model changed by an increasing transformation of th
The fitted values are calculated by substituting in the vector values of the independent variable to the coefficient estimates (in this case of the median). $y = mx +c$. There is a direct linear rela
Why are the predictions of a quantile regression model changed by an increasing transformation of the DV? The fitted values are calculated by substituting in the vector values of the independent variable to the coefficient estimates (in this case of the median). $y = mx +c$. There is a direct linear relationship betwe...
Why are the predictions of a quantile regression model changed by an increasing transformation of th The fitted values are calculated by substituting in the vector values of the independent variable to the coefficient estimates (in this case of the median). $y = mx +c$. There is a direct linear rela
55,046
Financial Slang and NLP for Sentiment Analysis
you could try word2vec, which has a nice implementation in Gensim library. It should end up having similar vectors for the abbreviation (or slang) and the full word, and certainly can be used with sent. analysis . You could train it on a large number of tweets if there is a financial set somewhere? You would then use ...
Financial Slang and NLP for Sentiment Analysis
you could try word2vec, which has a nice implementation in Gensim library. It should end up having similar vectors for the abbreviation (or slang) and the full word, and certainly can be used with se
Financial Slang and NLP for Sentiment Analysis you could try word2vec, which has a nice implementation in Gensim library. It should end up having similar vectors for the abbreviation (or slang) and the full word, and certainly can be used with sent. analysis . You could train it on a large number of tweets if there is...
Financial Slang and NLP for Sentiment Analysis you could try word2vec, which has a nice implementation in Gensim library. It should end up having similar vectors for the abbreviation (or slang) and the full word, and certainly can be used with se
55,047
Financial Slang and NLP for Sentiment Analysis
You could use Kim's Character-Aware Neural Language Models https://arxiv.org/abs/1508.06615 as an alternative to word2vec. It uses a CNN over character inputs to produce a fixed size vector for each word. It can scale to previously unseen words. This feature of scaling to previously unseen words is why I prefer it over...
Financial Slang and NLP for Sentiment Analysis
You could use Kim's Character-Aware Neural Language Models https://arxiv.org/abs/1508.06615 as an alternative to word2vec. It uses a CNN over character inputs to produce a fixed size vector for each w
Financial Slang and NLP for Sentiment Analysis You could use Kim's Character-Aware Neural Language Models https://arxiv.org/abs/1508.06615 as an alternative to word2vec. It uses a CNN over character inputs to produce a fixed size vector for each word. It can scale to previously unseen words. This feature of scaling to ...
Financial Slang and NLP for Sentiment Analysis You could use Kim's Character-Aware Neural Language Models https://arxiv.org/abs/1508.06615 as an alternative to word2vec. It uses a CNN over character inputs to produce a fixed size vector for each w
55,048
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manner?
The "suggested algorithm" is incorrect. One way to see why that is so is to count the number of equiprobable permutations performed by the algorithm. At each step there are $m$ possible values for $k$, whence after $n$ steps there are $m^n$ possible results. Although many results will be duplicated, the point is tha...
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manne
The "suggested algorithm" is incorrect. One way to see why that is so is to count the number of equiprobable permutations performed by the algorithm. At each step there are $m$ possible values for $
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manner? The "suggested algorithm" is incorrect. One way to see why that is so is to count the number of equiprobable permutations performed by the algorithm. At each step there are $m$ possible values for $k$, whence after ...
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manne The "suggested algorithm" is incorrect. One way to see why that is so is to count the number of equiprobable permutations performed by the algorithm. At each step there are $m$ possible values for $
55,049
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manner?
Start at the beginning of the list. Pick the element with probability equal to $\frac{n}{m}$. If it is chosen set $n = n - 1$. Set $m = m - 1$ Now pass on to the next element and repeat until either $n$ or $m$ is zero. Not tested in detail but should work. Or use the facilities of your favourite statistical software.
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manne
Start at the beginning of the list. Pick the element with probability equal to $\frac{n}{m}$. If it is chosen set $n = n - 1$. Set $m = m - 1$ Now pass on to the next element and repeat until either $
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manner? Start at the beginning of the list. Pick the element with probability equal to $\frac{n}{m}$. If it is chosen set $n = n - 1$. Set $m = m - 1$ Now pass on to the next element and repeat until either $n$ or $m$ is zero...
How to efficiently choose $n$ subset out of a set of $m$ many numbers, in a randomized uniform manne Start at the beginning of the list. Pick the element with probability equal to $\frac{n}{m}$. If it is chosen set $n = n - 1$. Set $m = m - 1$ Now pass on to the next element and repeat until either $
55,050
Propensity Score Matching for more than 2 groups
Check out the WeightIt package. You can simply provide a factor treatment variable and covariates and it will estimate balancing weights for that treatment. It provides an interface to other packages and methods that do this using a unified syntax. Currently, it provides support for estimating balancing weighting for m...
Propensity Score Matching for more than 2 groups
Check out the WeightIt package. You can simply provide a factor treatment variable and covariates and it will estimate balancing weights for that treatment. It provides an interface to other packages
Propensity Score Matching for more than 2 groups Check out the WeightIt package. You can simply provide a factor treatment variable and covariates and it will estimate balancing weights for that treatment. It provides an interface to other packages and methods that do this using a unified syntax. Currently, it provides...
Propensity Score Matching for more than 2 groups Check out the WeightIt package. You can simply provide a factor treatment variable and covariates and it will estimate balancing weights for that treatment. It provides an interface to other packages
55,051
Propensity Score Matching for more than 2 groups
Propensity score calculation and subsequent paired analysis is possible in several ways. There are already some overlapping Q&A in CV that you might wish to look at: Propensity Score Matching in R with Multiple Treatments Software that matches 6 groups by propensity score? Comparing two or more treatments with invers...
Propensity Score Matching for more than 2 groups
Propensity score calculation and subsequent paired analysis is possible in several ways. There are already some overlapping Q&A in CV that you might wish to look at: Propensity Score Matching in R wi
Propensity Score Matching for more than 2 groups Propensity score calculation and subsequent paired analysis is possible in several ways. There are already some overlapping Q&A in CV that you might wish to look at: Propensity Score Matching in R with Multiple Treatments Software that matches 6 groups by propensity sco...
Propensity Score Matching for more than 2 groups Propensity score calculation and subsequent paired analysis is possible in several ways. There are already some overlapping Q&A in CV that you might wish to look at: Propensity Score Matching in R wi
55,052
Propensity Score Matching for more than 2 groups
I have mostly used PSM for 2 class problems. We predict the probability of the treatment. And then compare effect of treatment vs control in same decile of our probability scores. Customers in same decile typically are similar and so comparable. So you can repeat the PSM twice. Control each time being people who have ...
Propensity Score Matching for more than 2 groups
I have mostly used PSM for 2 class problems. We predict the probability of the treatment. And then compare effect of treatment vs control in same decile of our probability scores. Customers in same de
Propensity Score Matching for more than 2 groups I have mostly used PSM for 2 class problems. We predict the probability of the treatment. And then compare effect of treatment vs control in same decile of our probability scores. Customers in same decile typically are similar and so comparable. So you can repeat the PS...
Propensity Score Matching for more than 2 groups I have mostly used PSM for 2 class problems. We predict the probability of the treatment. And then compare effect of treatment vs control in same decile of our probability scores. Customers in same de
55,053
Generating random numbers from a multiplication of CDFs
If the $X_i$s are independent, $G(x)$ is the CDF of the maximum of $X_1,\ldots,X_n$, since \begin{equation} \mathbb{P}(\max ( X_1,X_2,\ldots,X_n) \leq x) = \mathbb{P}(X_1, \leq x, X_2\leq x \ldots, X_n \leq x) \\ = \mathbb{P}(X_1 \leq x)\,\mathbb{P}(X_2 \leq x)\,\ldots\,\mathbb{P}(X_n \leq x) = F_1(x)\,F_2(x)\,\ldots\,...
Generating random numbers from a multiplication of CDFs
If the $X_i$s are independent, $G(x)$ is the CDF of the maximum of $X_1,\ldots,X_n$, since \begin{equation} \mathbb{P}(\max ( X_1,X_2,\ldots,X_n) \leq x) = \mathbb{P}(X_1, \leq x, X_2\leq x \ldots, X_
Generating random numbers from a multiplication of CDFs If the $X_i$s are independent, $G(x)$ is the CDF of the maximum of $X_1,\ldots,X_n$, since \begin{equation} \mathbb{P}(\max ( X_1,X_2,\ldots,X_n) \leq x) = \mathbb{P}(X_1, \leq x, X_2\leq x \ldots, X_n \leq x) \\ = \mathbb{P}(X_1 \leq x)\,\mathbb{P}(X_2 \leq x)\,\...
Generating random numbers from a multiplication of CDFs If the $X_i$s are independent, $G(x)$ is the CDF of the maximum of $X_1,\ldots,X_n$, since \begin{equation} \mathbb{P}(\max ( X_1,X_2,\ldots,X_n) \leq x) = \mathbb{P}(X_1, \leq x, X_2\leq x \ldots, X_
55,054
How can calculate number of weights in LSTM
Each cell in the LSTM has four components: the cell weights, the input gate, the forget gate, and the output gate. Each component has weights associated with all of its input from the previous layer, plus input from the previous time step. So if there are $n_i$ cells in an LSTM layer, and $n_{i-1}$ in the earlier lay...
How can calculate number of weights in LSTM
Each cell in the LSTM has four components: the cell weights, the input gate, the forget gate, and the output gate. Each component has weights associated with all of its input from the previous layer,
How can calculate number of weights in LSTM Each cell in the LSTM has four components: the cell weights, the input gate, the forget gate, and the output gate. Each component has weights associated with all of its input from the previous layer, plus input from the previous time step. So if there are $n_i$ cells in an ...
How can calculate number of weights in LSTM Each cell in the LSTM has four components: the cell weights, the input gate, the forget gate, and the output gate. Each component has weights associated with all of its input from the previous layer,
55,055
How can calculate number of weights in LSTM
I think this may be my answer. If LSTM don't use recurrent projection layer and non-recurrent projection layer, use this equivalent. (nc*nc*4*di)+(ni*nc*4*di)+(nc*no)+(nc*3*di) nc = number of LSTM cells ni = number of input no = numbre of output di = number of layers if LSTM use projection layer, number of weights ob...
How can calculate number of weights in LSTM
I think this may be my answer. If LSTM don't use recurrent projection layer and non-recurrent projection layer, use this equivalent. (nc*nc*4*di)+(ni*nc*4*di)+(nc*no)+(nc*3*di) nc = number of LSTM ce
How can calculate number of weights in LSTM I think this may be my answer. If LSTM don't use recurrent projection layer and non-recurrent projection layer, use this equivalent. (nc*nc*4*di)+(ni*nc*4*di)+(nc*no)+(nc*3*di) nc = number of LSTM cells ni = number of input no = numbre of output di = number of layers if LST...
How can calculate number of weights in LSTM I think this may be my answer. If LSTM don't use recurrent projection layer and non-recurrent projection layer, use this equivalent. (nc*nc*4*di)+(ni*nc*4*di)+(nc*no)+(nc*3*di) nc = number of LSTM ce
55,056
How can calculate number of weights in LSTM
Total number of weights in LSTM N/W = 4 x inp_dim x (inp_dim + out_dim + 1) So, in your first model: For Stage-1(input --> h1): inp_dim = 39; out_dim = 1024 Therefore, weights of stage-1 = 4 x 39 x (39 + 1024 + 1) = 0.165M For Stage-2(h1 --> h2): inp_dim = 1024; out_dim = 1024 Therefore, weights of stage-2 = 4 x 1024 x...
How can calculate number of weights in LSTM
Total number of weights in LSTM N/W = 4 x inp_dim x (inp_dim + out_dim + 1) So, in your first model: For Stage-1(input --> h1): inp_dim = 39; out_dim = 1024 Therefore, weights of stage-1 = 4 x 39 x (3
How can calculate number of weights in LSTM Total number of weights in LSTM N/W = 4 x inp_dim x (inp_dim + out_dim + 1) So, in your first model: For Stage-1(input --> h1): inp_dim = 39; out_dim = 1024 Therefore, weights of stage-1 = 4 x 39 x (39 + 1024 + 1) = 0.165M For Stage-2(h1 --> h2): inp_dim = 1024; out_dim = 102...
How can calculate number of weights in LSTM Total number of weights in LSTM N/W = 4 x inp_dim x (inp_dim + out_dim + 1) So, in your first model: For Stage-1(input --> h1): inp_dim = 39; out_dim = 1024 Therefore, weights of stage-1 = 4 x 39 x (3
55,057
How many lags should I include in time series prediction?
Looking at individual autocorrelations may help in simple cases, but this way you could miss lags that are important only jointly but not individually. Alternatively, you may try the following: Select a large number of lags and estimate a penalized model (e.g. using LASSO, ridge or elastic net regularization). The pen...
How many lags should I include in time series prediction?
Looking at individual autocorrelations may help in simple cases, but this way you could miss lags that are important only jointly but not individually. Alternatively, you may try the following: Selec
How many lags should I include in time series prediction? Looking at individual autocorrelations may help in simple cases, but this way you could miss lags that are important only jointly but not individually. Alternatively, you may try the following: Select a large number of lags and estimate a penalized model (e.g. ...
How many lags should I include in time series prediction? Looking at individual autocorrelations may help in simple cases, but this way you could miss lags that are important only jointly but not individually. Alternatively, you may try the following: Selec
55,058
Method for quantifying intervention effect in time series
In general, evaluation of pre-post effects in time-series analysis is called interrupted time series. This is a very general modeling approach that tests the strong hypothesis: $\mathcal{H}_0: \mu_{ijt} = f_i(t)$ versus $\mathcal{H}_1 : \mu_{ijt} = f_i(t) + \beta(t)X_{ijt} $ Where $X_{ijt}$ is the the treatment assignm...
Method for quantifying intervention effect in time series
In general, evaluation of pre-post effects in time-series analysis is called interrupted time series. This is a very general modeling approach that tests the strong hypothesis: $\mathcal{H}_0: \mu_{ij
Method for quantifying intervention effect in time series In general, evaluation of pre-post effects in time-series analysis is called interrupted time series. This is a very general modeling approach that tests the strong hypothesis: $\mathcal{H}_0: \mu_{ijt} = f_i(t)$ versus $\mathcal{H}_1 : \mu_{ijt} = f_i(t) + \bet...
Method for quantifying intervention effect in time series In general, evaluation of pre-post effects in time-series analysis is called interrupted time series. This is a very general modeling approach that tests the strong hypothesis: $\mathcal{H}_0: \mu_{ij
55,059
Method for quantifying intervention effect in time series
Repeating your data-generating code for convenience ... set.seed(101) ## don't to forget to set the seed for reproducibility ##generate a comparable time-series ts() base <- rnbinom(n = 120, size = 1400, prob = 0.5) season <- rep(c(600, 400, 150, 0, -50, -80, -300, -600, 50, 100, 200, 300), 10) ## dangerous to name ...
Method for quantifying intervention effect in time series
Repeating your data-generating code for convenience ... set.seed(101) ## don't to forget to set the seed for reproducibility ##generate a comparable time-series ts() base <- rnbinom(n = 120, size =
Method for quantifying intervention effect in time series Repeating your data-generating code for convenience ... set.seed(101) ## don't to forget to set the seed for reproducibility ##generate a comparable time-series ts() base <- rnbinom(n = 120, size = 1400, prob = 0.5) season <- rep(c(600, 400, 150, 0, -50, -80, ...
Method for quantifying intervention effect in time series Repeating your data-generating code for convenience ... set.seed(101) ## don't to forget to set the seed for reproducibility ##generate a comparable time-series ts() base <- rnbinom(n = 120, size =
55,060
Logistic regression with only categorical predictors
Yeah, it's perfectly acceptable for a logistic regression to contain only categorical predictors. Remember that we code categorical predictors numerically (e.g., 0 and 1, -1 and 1, etc.), so the distinction between categorical and continuous doesn't really exist for the regression. As for how to plot the effect, I woul...
Logistic regression with only categorical predictors
Yeah, it's perfectly acceptable for a logistic regression to contain only categorical predictors. Remember that we code categorical predictors numerically (e.g., 0 and 1, -1 and 1, etc.), so the disti
Logistic regression with only categorical predictors Yeah, it's perfectly acceptable for a logistic regression to contain only categorical predictors. Remember that we code categorical predictors numerically (e.g., 0 and 1, -1 and 1, etc.), so the distinction between categorical and continuous doesn't really exist for ...
Logistic regression with only categorical predictors Yeah, it's perfectly acceptable for a logistic regression to contain only categorical predictors. Remember that we code categorical predictors numerically (e.g., 0 and 1, -1 and 1, etc.), so the disti
55,061
Logistic regression with only categorical predictors
It certainly is allowed. I would suggest you choose a new approach to visualizing your data, other than the sigmoid curve. As you said being categorical means you do not have a range of data to assess your probabilities over. Categorical variables are either there or not. One approach that comes to my mind, is to plot ...
Logistic regression with only categorical predictors
It certainly is allowed. I would suggest you choose a new approach to visualizing your data, other than the sigmoid curve. As you said being categorical means you do not have a range of data to assess
Logistic regression with only categorical predictors It certainly is allowed. I would suggest you choose a new approach to visualizing your data, other than the sigmoid curve. As you said being categorical means you do not have a range of data to assess your probabilities over. Categorical variables are either there or...
Logistic regression with only categorical predictors It certainly is allowed. I would suggest you choose a new approach to visualizing your data, other than the sigmoid curve. As you said being categorical means you do not have a range of data to assess
55,062
Confusion about when to use least-squares regression analysis
The two sections you quote are not directly comparable, I think. Some background: In OLS regression, the assumptions of the process (which are not always considered by its users, as noted by the author of that article) include the requirement that the independent variable(s) be measured perfectly--that is, with zero me...
Confusion about when to use least-squares regression analysis
The two sections you quote are not directly comparable, I think. Some background: In OLS regression, the assumptions of the process (which are not always considered by its users, as noted by the autho
Confusion about when to use least-squares regression analysis The two sections you quote are not directly comparable, I think. Some background: In OLS regression, the assumptions of the process (which are not always considered by its users, as noted by the author of that article) include the requirement that the indepe...
Confusion about when to use least-squares regression analysis The two sections you quote are not directly comparable, I think. Some background: In OLS regression, the assumptions of the process (which are not always considered by its users, as noted by the autho
55,063
Confusion about when to use least-squares regression analysis
Just to clarify some points from DL Rogers' answer. OLS regression estimates the mean of the conditional distribution $E(y|x)$. Clearly, in a prediction problem, this is what we want: we are given $x$ and want to predict $y$. Since the $x$ is hypothetical, it can be assumed to be without error. In prediction, we're say...
Confusion about when to use least-squares regression analysis
Just to clarify some points from DL Rogers' answer. OLS regression estimates the mean of the conditional distribution $E(y|x)$. Clearly, in a prediction problem, this is what we want: we are given $x$
Confusion about when to use least-squares regression analysis Just to clarify some points from DL Rogers' answer. OLS regression estimates the mean of the conditional distribution $E(y|x)$. Clearly, in a prediction problem, this is what we want: we are given $x$ and want to predict $y$. Since the $x$ is hypothetical, i...
Confusion about when to use least-squares regression analysis Just to clarify some points from DL Rogers' answer. OLS regression estimates the mean of the conditional distribution $E(y|x)$. Clearly, in a prediction problem, this is what we want: we are given $x$
55,064
Does a confidence interval carry some extra error for non perfectly normal distributions?
When we talk about a 95% confidence interval for that sample mean, i understand it as saying "given that we assume a normal distribution for the sampling distribution of the sample means of samples of size n=100, there's a 95% chance that the mean of our sample falls at a point under our sampling distribution (...
Does a confidence interval carry some extra error for non perfectly normal distributions?
When we talk about a 95% confidence interval for that sample mean, i understand it as saying "given that we assume a normal distribution for the sampling distribution of the sample means of sample
Does a confidence interval carry some extra error for non perfectly normal distributions? When we talk about a 95% confidence interval for that sample mean, i understand it as saying "given that we assume a normal distribution for the sampling distribution of the sample means of samples of size n=100, there's a 9...
Does a confidence interval carry some extra error for non perfectly normal distributions? When we talk about a 95% confidence interval for that sample mean, i understand it as saying "given that we assume a normal distribution for the sampling distribution of the sample means of sample
55,065
Does a confidence interval carry some extra error for non perfectly normal distributions?
The answer by @Greenparker is an excellent answer that highlights a common misconception, but I want to try to address your question more directly. You are correct to say that if your model is wrong (student heights are not normal) then your confidence intervals might not be as accurate as they claim. The issue then li...
Does a confidence interval carry some extra error for non perfectly normal distributions?
The answer by @Greenparker is an excellent answer that highlights a common misconception, but I want to try to address your question more directly. You are correct to say that if your model is wrong (
Does a confidence interval carry some extra error for non perfectly normal distributions? The answer by @Greenparker is an excellent answer that highlights a common misconception, but I want to try to address your question more directly. You are correct to say that if your model is wrong (student heights are not normal...
Does a confidence interval carry some extra error for non perfectly normal distributions? The answer by @Greenparker is an excellent answer that highlights a common misconception, but I want to try to address your question more directly. You are correct to say that if your model is wrong (
55,066
Dynamic treatment timing in a panel-DiD framework
You construct the policy dummy the way you first describe it, i.e. create a column of zeroes. Then for each firm you replace this with ones if a firm is in the treatment group AND it is in the post-treatment period. Something like this $$ \begin{array}{ccccc} \text{firm} & \text{time} & \text{treated} & \text{post} & \...
Dynamic treatment timing in a panel-DiD framework
You construct the policy dummy the way you first describe it, i.e. create a column of zeroes. Then for each firm you replace this with ones if a firm is in the treatment group AND it is in the post-tr
Dynamic treatment timing in a panel-DiD framework You construct the policy dummy the way you first describe it, i.e. create a column of zeroes. Then for each firm you replace this with ones if a firm is in the treatment group AND it is in the post-treatment period. Something like this $$ \begin{array}{ccccc} \text{firm...
Dynamic treatment timing in a panel-DiD framework You construct the policy dummy the way you first describe it, i.e. create a column of zeroes. Then for each firm you replace this with ones if a firm is in the treatment group AND it is in the post-tr
55,067
Correlation multinomial distribution
The probability generating function is $$\eqalign{ f(x_1,\ldots, x_c) &= \sum_{k_1, \ldots, k_c} \Pr((X_1,\ldots,X_c)=(k_1,\ldots, k_c)) x_1^{k_1}\cdots x_c^{k_c}\\ &= \sum_{k_1,\ldots,k_c} \binom{n}{k_1\cdots k_c} (\pi_1 x_1)^{k_1}\cdots (\pi_c x_c)^{k_c} \\ &= (\pi_1 x_1 + \cdots + \pi_c x_c)^n.\tag{1} }$$ The first ...
Correlation multinomial distribution
The probability generating function is $$\eqalign{ f(x_1,\ldots, x_c) &= \sum_{k_1, \ldots, k_c} \Pr((X_1,\ldots,X_c)=(k_1,\ldots, k_c)) x_1^{k_1}\cdots x_c^{k_c}\\ &= \sum_{k_1,\ldots,k_c} \binom{n}{
Correlation multinomial distribution The probability generating function is $$\eqalign{ f(x_1,\ldots, x_c) &= \sum_{k_1, \ldots, k_c} \Pr((X_1,\ldots,X_c)=(k_1,\ldots, k_c)) x_1^{k_1}\cdots x_c^{k_c}\\ &= \sum_{k_1,\ldots,k_c} \binom{n}{k_1\cdots k_c} (\pi_1 x_1)^{k_1}\cdots (\pi_c x_c)^{k_c} \\ &= (\pi_1 x_1 + \cdots ...
Correlation multinomial distribution The probability generating function is $$\eqalign{ f(x_1,\ldots, x_c) &= \sum_{k_1, \ldots, k_c} \Pr((X_1,\ldots,X_c)=(k_1,\ldots, k_c)) x_1^{k_1}\cdots x_c^{k_c}\\ &= \sum_{k_1,\ldots,k_c} \binom{n}{
55,068
Sampling without Replacement and Non-uniform Distribution
Sounds like you are looking for the multivariate Wallenius' noncentral hypergeometric distribution. ie weighted balls, multiple colors, multiple draws.wikipedia link I did try to find something analytic, but even in simple cases this problem becomes increasingly complicated. I would advise looking at some of the packag...
Sampling without Replacement and Non-uniform Distribution
Sounds like you are looking for the multivariate Wallenius' noncentral hypergeometric distribution. ie weighted balls, multiple colors, multiple draws.wikipedia link I did try to find something analyt
Sampling without Replacement and Non-uniform Distribution Sounds like you are looking for the multivariate Wallenius' noncentral hypergeometric distribution. ie weighted balls, multiple colors, multiple draws.wikipedia link I did try to find something analytic, but even in simple cases this problem becomes increasingly...
Sampling without Replacement and Non-uniform Distribution Sounds like you are looking for the multivariate Wallenius' noncentral hypergeometric distribution. ie weighted balls, multiple colors, multiple draws.wikipedia link I did try to find something analyt
55,069
Sampling without Replacement and Non-uniform Distribution
A long comment which I have have had to post as an answer. I have no objection if some kindly Moderator converts it into a series of comments on the main question. Your question is essentially unanswerable in one sense. You have told us that the probability of drawing the $i$-th object on the first draw is $p_i$. In...
Sampling without Replacement and Non-uniform Distribution
A long comment which I have have had to post as an answer. I have no objection if some kindly Moderator converts it into a series of comments on the main question. Your question is essentially unansw
Sampling without Replacement and Non-uniform Distribution A long comment which I have have had to post as an answer. I have no objection if some kindly Moderator converts it into a series of comments on the main question. Your question is essentially unanswerable in one sense. You have told us that the probability of...
Sampling without Replacement and Non-uniform Distribution A long comment which I have have had to post as an answer. I have no objection if some kindly Moderator converts it into a series of comments on the main question. Your question is essentially unansw
55,070
Sampling without Replacement and Non-uniform Distribution
Since you asked for an approximation, I will propose one. It's not perfect: it requires additional reasonable assumptions; I won't prove it's accurate; I'm not sure it's a valid pmf. If $N$ is large, $K << N$, and the $p_j's$ are small, then drawing once gives a probability of $p_j$. The next draw will be only slightl...
Sampling without Replacement and Non-uniform Distribution
Since you asked for an approximation, I will propose one. It's not perfect: it requires additional reasonable assumptions; I won't prove it's accurate; I'm not sure it's a valid pmf. If $N$ is large,
Sampling without Replacement and Non-uniform Distribution Since you asked for an approximation, I will propose one. It's not perfect: it requires additional reasonable assumptions; I won't prove it's accurate; I'm not sure it's a valid pmf. If $N$ is large, $K << N$, and the $p_j's$ are small, then drawing once gives ...
Sampling without Replacement and Non-uniform Distribution Since you asked for an approximation, I will propose one. It's not perfect: it requires additional reasonable assumptions; I won't prove it's accurate; I'm not sure it's a valid pmf. If $N$ is large,
55,071
Intuition about f1 score
So this is a confusion matrix in case any readers haven't seen one: $$ \begin{array}{l c c} & Predict + & Predict-\\ Actual + & a & b \\ Actual - & c & d \\ \end{array} $$ And this is the formula for calculating $F_1$ from a confusion matrix: $$F_1 = \frac{2a}{2a+b+c}$$ So if half the items are positive in reality and ...
Intuition about f1 score
So this is a confusion matrix in case any readers haven't seen one: $$ \begin{array}{l c c} & Predict + & Predict-\\ Actual + & a & b \\ Actual - & c & d \\ \end{array} $$ And this is the formula for
Intuition about f1 score So this is a confusion matrix in case any readers haven't seen one: $$ \begin{array}{l c c} & Predict + & Predict-\\ Actual + & a & b \\ Actual - & c & d \\ \end{array} $$ And this is the formula for calculating $F_1$ from a confusion matrix: $$F_1 = \frac{2a}{2a+b+c}$$ So if half the items are...
Intuition about f1 score So this is a confusion matrix in case any readers haven't seen one: $$ \begin{array}{l c c} & Predict + & Predict-\\ Actual + & a & b \\ Actual - & c & d \\ \end{array} $$ And this is the formula for
55,072
How does alpha relate to C in Scikit-Learn's SGDClassifier?
The correct scaling is C_svc * n_samples = 1 / alpha_sgd instead of C_svc = n_samples / alpha_sgd, the documentation seems to be incorrect. In your example, it gives alpha = 0.002, and the results are similar with the SVC estimator's. After a quick overview, it seems that the equivalence is: 1. / C_svr ~ 1. / C_svc ~ 1...
How does alpha relate to C in Scikit-Learn's SGDClassifier?
The correct scaling is C_svc * n_samples = 1 / alpha_sgd instead of C_svc = n_samples / alpha_sgd, the documentation seems to be incorrect. In your example, it gives alpha = 0.002, and the results are
How does alpha relate to C in Scikit-Learn's SGDClassifier? The correct scaling is C_svc * n_samples = 1 / alpha_sgd instead of C_svc = n_samples / alpha_sgd, the documentation seems to be incorrect. In your example, it gives alpha = 0.002, and the results are similar with the SVC estimator's. After a quick overview, i...
How does alpha relate to C in Scikit-Learn's SGDClassifier? The correct scaling is C_svc * n_samples = 1 / alpha_sgd instead of C_svc = n_samples / alpha_sgd, the documentation seems to be incorrect. In your example, it gives alpha = 0.002, and the results are
55,073
Advantages of convolutional neural networks over "simple" feed-forward networks?
Any time that you can legitimately make stronger assumptions, you can obtain stronger results. Convolutional networks make the assumption of locality, and hence are more powerful. This depends on data that in fact exhibits locality (autocorrelation) like images or time series. Intuitively, if you are looking at an imag...
Advantages of convolutional neural networks over "simple" feed-forward networks?
Any time that you can legitimately make stronger assumptions, you can obtain stronger results. Convolutional networks make the assumption of locality, and hence are more powerful. This depends on data
Advantages of convolutional neural networks over "simple" feed-forward networks? Any time that you can legitimately make stronger assumptions, you can obtain stronger results. Convolutional networks make the assumption of locality, and hence are more powerful. This depends on data that in fact exhibits locality (autoco...
Advantages of convolutional neural networks over "simple" feed-forward networks? Any time that you can legitimately make stronger assumptions, you can obtain stronger results. Convolutional networks make the assumption of locality, and hence are more powerful. This depends on data
55,074
Advantages of convolutional neural networks over "simple" feed-forward networks?
Deep nets are a general class whose solely mandatory characteristic is an unusual number of neural layers, whereas convolutional networks are a specific technique that can be included in a deep net, alongside other techniques such as LSTMs, perceptrons, Kohonen nets, etc. Keep in mind that "deep learning" is something ...
Advantages of convolutional neural networks over "simple" feed-forward networks?
Deep nets are a general class whose solely mandatory characteristic is an unusual number of neural layers, whereas convolutional networks are a specific technique that can be included in a deep net, a
Advantages of convolutional neural networks over "simple" feed-forward networks? Deep nets are a general class whose solely mandatory characteristic is an unusual number of neural layers, whereas convolutional networks are a specific technique that can be included in a deep net, alongside other techniques such as LSTMs...
Advantages of convolutional neural networks over "simple" feed-forward networks? Deep nets are a general class whose solely mandatory characteristic is an unusual number of neural layers, whereas convolutional networks are a specific technique that can be included in a deep net, a
55,075
Advantages of convolutional neural networks over "simple" feed-forward networks?
The sentence said by @Wayne summarizes it pretty well - "Any time that you can legitimately make stronger assumptions, you can obtain stronger results". Though, a bit more detail can be added to why CNNs are superior models for image data compared to the multi-layer perceptron. Fully connected layers are the fundamenta...
Advantages of convolutional neural networks over "simple" feed-forward networks?
The sentence said by @Wayne summarizes it pretty well - "Any time that you can legitimately make stronger assumptions, you can obtain stronger results". Though, a bit more detail can be added to why C
Advantages of convolutional neural networks over "simple" feed-forward networks? The sentence said by @Wayne summarizes it pretty well - "Any time that you can legitimately make stronger assumptions, you can obtain stronger results". Though, a bit more detail can be added to why CNNs are superior models for image data ...
Advantages of convolutional neural networks over "simple" feed-forward networks? The sentence said by @Wayne summarizes it pretty well - "Any time that you can legitimately make stronger assumptions, you can obtain stronger results". Though, a bit more detail can be added to why C
55,076
Maximum of a set of values from given mean and median
This is quite straightforward. Start with any five different natural numbers* with the required properties (median and mean both 7) and then see how you can change them without changing the mean or the median. * As Adrian notes and as discussed at the link above, whether the natural numbers includes 0 depends on who y...
Maximum of a set of values from given mean and median
This is quite straightforward. Start with any five different natural numbers* with the required properties (median and mean both 7) and then see how you can change them without changing the mean or th
Maximum of a set of values from given mean and median This is quite straightforward. Start with any five different natural numbers* with the required properties (median and mean both 7) and then see how you can change them without changing the mean or the median. * As Adrian notes and as discussed at the link above, w...
Maximum of a set of values from given mean and median This is quite straightforward. Start with any five different natural numbers* with the required properties (median and mean both 7) and then see how you can change them without changing the mean or th
55,077
Simple question about Ornstein-Uhlenbeck process
The method discussed in the article you mention is directly inspired from the paper 'Statistical Arbitrage in the U.S. Equities Market' by Avellaneda & Lee (2008). Most of your questions are answered in the Appendix p.44. Suppose we are at the end of trading day $D$. In the Avellaneda & Lee paper the s-score is define...
Simple question about Ornstein-Uhlenbeck process
The method discussed in the article you mention is directly inspired from the paper 'Statistical Arbitrage in the U.S. Equities Market' by Avellaneda & Lee (2008). Most of your questions are answered
Simple question about Ornstein-Uhlenbeck process The method discussed in the article you mention is directly inspired from the paper 'Statistical Arbitrage in the U.S. Equities Market' by Avellaneda & Lee (2008). Most of your questions are answered in the Appendix p.44. Suppose we are at the end of trading day $D$. In...
Simple question about Ornstein-Uhlenbeck process The method discussed in the article you mention is directly inspired from the paper 'Statistical Arbitrage in the U.S. Equities Market' by Avellaneda & Lee (2008). Most of your questions are answered
55,078
Does Bonferroni apply to inference from parametric and non-parametric models?
As umm... Mr. Bonferroni notes, his correction works on any p-values, regardless of their source. However, there are other procedures, like the Holm's, which are uniformly more powerful; subject to certain other restrictions, like positive dependence between the tests, other methods are even more powerful still. Sorry,...
Does Bonferroni apply to inference from parametric and non-parametric models?
As umm... Mr. Bonferroni notes, his correction works on any p-values, regardless of their source. However, there are other procedures, like the Holm's, which are uniformly more powerful; subject to ce
Does Bonferroni apply to inference from parametric and non-parametric models? As umm... Mr. Bonferroni notes, his correction works on any p-values, regardless of their source. However, there are other procedures, like the Holm's, which are uniformly more powerful; subject to certain other restrictions, like positive de...
Does Bonferroni apply to inference from parametric and non-parametric models? As umm... Mr. Bonferroni notes, his correction works on any p-values, regardless of their source. However, there are other procedures, like the Holm's, which are uniformly more powerful; subject to ce
55,079
Does Bonferroni apply to inference from parametric and non-parametric models?
Bonferroni works for any p-values. It doesn't care where they came from.
Does Bonferroni apply to inference from parametric and non-parametric models?
Bonferroni works for any p-values. It doesn't care where they came from.
Does Bonferroni apply to inference from parametric and non-parametric models? Bonferroni works for any p-values. It doesn't care where they came from.
Does Bonferroni apply to inference from parametric and non-parametric models? Bonferroni works for any p-values. It doesn't care where they came from.
55,080
Does Bonferroni apply to inference from parametric and non-parametric models?
If you want to correct then there are stronger methods than that named after Bonferroni like Holm's method which is always applicable when Bonferroni is and is never less powerful. However is that really what you want to do if you have a precise hypothesis about which will achieve some arbitrary level of statistical si...
Does Bonferroni apply to inference from parametric and non-parametric models?
If you want to correct then there are stronger methods than that named after Bonferroni like Holm's method which is always applicable when Bonferroni is and is never less powerful. However is that rea
Does Bonferroni apply to inference from parametric and non-parametric models? If you want to correct then there are stronger methods than that named after Bonferroni like Holm's method which is always applicable when Bonferroni is and is never less powerful. However is that really what you want to do if you have a prec...
Does Bonferroni apply to inference from parametric and non-parametric models? If you want to correct then there are stronger methods than that named after Bonferroni like Holm's method which is always applicable when Bonferroni is and is never less powerful. However is that rea
55,081
Meaning of cross validation
You are right (for K-fold CV) K-fold CV is a metric that would provide a better measure of accuracy for your model than a regular single training-testing split. It would not do more than that. It would have no effect on the learning itself. However, cross validation or (just validation) is used in conjunction with lea...
Meaning of cross validation
You are right (for K-fold CV) K-fold CV is a metric that would provide a better measure of accuracy for your model than a regular single training-testing split. It would not do more than that. It wou
Meaning of cross validation You are right (for K-fold CV) K-fold CV is a metric that would provide a better measure of accuracy for your model than a regular single training-testing split. It would not do more than that. It would have no effect on the learning itself. However, cross validation or (just validation) is ...
Meaning of cross validation You are right (for K-fold CV) K-fold CV is a metric that would provide a better measure of accuracy for your model than a regular single training-testing split. It would not do more than that. It wou
55,082
Meaning of cross validation
Yes, you are correct. Cross validation will give you an idea of your model's out-of-sample performance. It does not modify the model as such. Typically, you will look at multiple models when you want to predict. (The situation is somewhat different when doing inferential statistics.) You will cross validate each model ...
Meaning of cross validation
Yes, you are correct. Cross validation will give you an idea of your model's out-of-sample performance. It does not modify the model as such. Typically, you will look at multiple models when you want
Meaning of cross validation Yes, you are correct. Cross validation will give you an idea of your model's out-of-sample performance. It does not modify the model as such. Typically, you will look at multiple models when you want to predict. (The situation is somewhat different when doing inferential statistics.) You wil...
Meaning of cross validation Yes, you are correct. Cross validation will give you an idea of your model's out-of-sample performance. It does not modify the model as such. Typically, you will look at multiple models when you want
55,083
Maximum Likelihood Estimator for equicorrelation model
The useful formulas have been given in the answer by @Alecos Papadopoulos, which I will refer to. Note that $\mathbf{\Sigma}$ is positive definite iff $\rho_{\text{min}} < \rho < 1$ with $\rho_{\text{min}} := - 1/(p-1)$. For the ML estimation you can concentrate the vector $\boldsymbol{\mu}$ and the scalar $\sigma^2$ o...
Maximum Likelihood Estimator for equicorrelation model
The useful formulas have been given in the answer by @Alecos Papadopoulos, which I will refer to. Note that $\mathbf{\Sigma}$ is positive definite iff $\rho_{\text{min}} < \rho < 1$ with $\rho_{\text{
Maximum Likelihood Estimator for equicorrelation model The useful formulas have been given in the answer by @Alecos Papadopoulos, which I will refer to. Note that $\mathbf{\Sigma}$ is positive definite iff $\rho_{\text{min}} < \rho < 1$ with $\rho_{\text{min}} := - 1/(p-1)$. For the ML estimation you can concentrate th...
Maximum Likelihood Estimator for equicorrelation model The useful formulas have been given in the answer by @Alecos Papadopoulos, which I will refer to. Note that $\mathbf{\Sigma}$ is positive definite iff $\rho_{\text{min}} < \rho < 1$ with $\rho_{\text{
55,084
Maximum Likelihood Estimator for equicorrelation model
One can verify that the inverse of this matrix equals $$\mathbf{\Sigma}^{-1} =\frac {1}{\sigma^2(1-\rho)}\left(\mathbf{I_p}-\frac{\rho}{1+(p-1)\rho}\mathbf{J_p}\right)$$ Its determinant is $$|\mathbf{\Sigma}| = \sigma^{2p}\cdot [1+(p-1)\rho]\cdot (1-\rho)^{p-1}$$ (see Tong 1990, p.104) I don't think it gets simpler tha...
Maximum Likelihood Estimator for equicorrelation model
One can verify that the inverse of this matrix equals $$\mathbf{\Sigma}^{-1} =\frac {1}{\sigma^2(1-\rho)}\left(\mathbf{I_p}-\frac{\rho}{1+(p-1)\rho}\mathbf{J_p}\right)$$ Its determinant is $$|\mathbf{
Maximum Likelihood Estimator for equicorrelation model One can verify that the inverse of this matrix equals $$\mathbf{\Sigma}^{-1} =\frac {1}{\sigma^2(1-\rho)}\left(\mathbf{I_p}-\frac{\rho}{1+(p-1)\rho}\mathbf{J_p}\right)$$ Its determinant is $$|\mathbf{\Sigma}| = \sigma^{2p}\cdot [1+(p-1)\rho]\cdot (1-\rho)^{p-1}$$ (...
Maximum Likelihood Estimator for equicorrelation model One can verify that the inverse of this matrix equals $$\mathbf{\Sigma}^{-1} =\frac {1}{\sigma^2(1-\rho)}\left(\mathbf{I_p}-\frac{\rho}{1+(p-1)\rho}\mathbf{J_p}\right)$$ Its determinant is $$|\mathbf{
55,085
Maximum Likelihood Estimator for equicorrelation model
There exists explicit (closed-form) solutions for the MLE's you are struggling to find. In fact, a little intuition, after the re-parametrization in step 1 shown below, reveals that the average of the diagonal elements of xx' is a reasonable estimator for the variance and the average of the off-diagonal elements of xx...
Maximum Likelihood Estimator for equicorrelation model
There exists explicit (closed-form) solutions for the MLE's you are struggling to find. In fact, a little intuition, after the re-parametrization in step 1 shown below, reveals that the average of th
Maximum Likelihood Estimator for equicorrelation model There exists explicit (closed-form) solutions for the MLE's you are struggling to find. In fact, a little intuition, after the re-parametrization in step 1 shown below, reveals that the average of the diagonal elements of xx' is a reasonable estimator for the vari...
Maximum Likelihood Estimator for equicorrelation model There exists explicit (closed-form) solutions for the MLE's you are struggling to find. In fact, a little intuition, after the re-parametrization in step 1 shown below, reveals that the average of th
55,086
Maximum Likelihood Estimator for equicorrelation model
I found this question in an exercise of Seber's Multivariate Observations (1984). I don't have a proof but apparently the maximum likelihood estimators of $\sigma^2$ and $\rho$ are given by $$\hat\sigma^2=\frac1p\sum_{j=1}^p s_{jj}$$ and $$\hat\rho=\frac1{\hat\sigma^2}\sum_{j\ne k}\frac{s_{jk}}{p(p-1)}\,,$$ where $s_{j...
Maximum Likelihood Estimator for equicorrelation model
I found this question in an exercise of Seber's Multivariate Observations (1984). I don't have a proof but apparently the maximum likelihood estimators of $\sigma^2$ and $\rho$ are given by $$\hat\sig
Maximum Likelihood Estimator for equicorrelation model I found this question in an exercise of Seber's Multivariate Observations (1984). I don't have a proof but apparently the maximum likelihood estimators of $\sigma^2$ and $\rho$ are given by $$\hat\sigma^2=\frac1p\sum_{j=1}^p s_{jj}$$ and $$\hat\rho=\frac1{\hat\sigm...
Maximum Likelihood Estimator for equicorrelation model I found this question in an exercise of Seber's Multivariate Observations (1984). I don't have a proof but apparently the maximum likelihood estimators of $\sigma^2$ and $\rho$ are given by $$\hat\sig
55,087
What is the domain of this random variable?
Often orthography hints at meaning. With this as a point of departure, along with an understanding of what a random variable is, we can figure out the rest. Rather than just giving an interpretation, I will first take you through the reasoning used to parse these expressions: that might help you make sense of related...
What is the domain of this random variable?
Often orthography hints at meaning. With this as a point of departure, along with an understanding of what a random variable is, we can figure out the rest. Rather than just giving an interpretation
What is the domain of this random variable? Often orthography hints at meaning. With this as a point of departure, along with an understanding of what a random variable is, we can figure out the rest. Rather than just giving an interpretation, I will first take you through the reasoning used to parse these expression...
What is the domain of this random variable? Often orthography hints at meaning. With this as a point of departure, along with an understanding of what a random variable is, we can figure out the rest. Rather than just giving an interpretation
55,088
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation?
Since ABC is an approximate method, the simplest answer to your question is that you can use any distance you find to your taste! Provided it is a true distance, the basis justification holds that $$\pi_\epsilon(\theta|y^{\text{obs}})=\pi(\theta|d(y(\theta), y^{\text{obs}})<\epsilon)$$where $y(\theta)\sim f(y|\theta)$ ...
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation
Since ABC is an approximate method, the simplest answer to your question is that you can use any distance you find to your taste! Provided it is a true distance, the basis justification holds that $$\
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation? Since ABC is an approximate method, the simplest answer to your question is that you can use any distance you find to your taste! Provided it is a true distance, the basis justification holds that $$\pi_\epsilon(\theta...
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation Since ABC is an approximate method, the simplest answer to your question is that you can use any distance you find to your taste! Provided it is a true distance, the basis justification holds that $$\
55,089
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation?
The Bhattacharyya distance is a distance between distributions while, what you need to conduct ABC, is a distance between summary statistics (this is, vectors of numbers that summarise the information in the sample), unless your summary statistic is a functional approximation to the distribution, which I doubt. For thi...
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation
The Bhattacharyya distance is a distance between distributions while, what you need to conduct ABC, is a distance between summary statistics (this is, vectors of numbers that summarise the information
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation? The Bhattacharyya distance is a distance between distributions while, what you need to conduct ABC, is a distance between summary statistics (this is, vectors of numbers that summarise the information in the sample), u...
Can I use the Bhattacharyya distance as an acceptance criterion for Approximate Bayesian Computation The Bhattacharyya distance is a distance between distributions while, what you need to conduct ABC, is a distance between summary statistics (this is, vectors of numbers that summarise the information
55,090
Self-studying the normal linear model: what can I do with it?
This is by no means authoritative, but hopefully it gives you somewhere to start. You've studied the model $Y = X\beta + \varepsilon$ with $\varepsilon \sim \mathcal N(0, \sigma^2 I)$. There are many extensions of this model. Some are: Explore different assumptions on $\varepsilon$. Maybe you only assume $E(\varepsilo...
Self-studying the normal linear model: what can I do with it?
This is by no means authoritative, but hopefully it gives you somewhere to start. You've studied the model $Y = X\beta + \varepsilon$ with $\varepsilon \sim \mathcal N(0, \sigma^2 I)$. There are many
Self-studying the normal linear model: what can I do with it? This is by no means authoritative, but hopefully it gives you somewhere to start. You've studied the model $Y = X\beta + \varepsilon$ with $\varepsilon \sim \mathcal N(0, \sigma^2 I)$. There are many extensions of this model. Some are: Explore different ass...
Self-studying the normal linear model: what can I do with it? This is by no means authoritative, but hopefully it gives you somewhere to start. You've studied the model $Y = X\beta + \varepsilon$ with $\varepsilon \sim \mathcal N(0, \sigma^2 I)$. There are many
55,091
Posteriors and Sample Sizes
The posterior is (generally) going to be a function of the sample size. One way of determining propriety of the posterior is to check the same size for which the parameters in the posterior are not defined. The example below is one such construction. $X_1, \dots, X_n \sim N(\theta, \sigma^2)$. For simplicity, let $\the...
Posteriors and Sample Sizes
The posterior is (generally) going to be a function of the sample size. One way of determining propriety of the posterior is to check the same size for which the parameters in the posterior are not de
Posteriors and Sample Sizes The posterior is (generally) going to be a function of the sample size. One way of determining propriety of the posterior is to check the same size for which the parameters in the posterior are not defined. The example below is one such construction. $X_1, \dots, X_n \sim N(\theta, \sigma^2)...
Posteriors and Sample Sizes The posterior is (generally) going to be a function of the sample size. One way of determining propriety of the posterior is to check the same size for which the parameters in the posterior are not de
55,092
Posteriors and Sample Sizes
A simple example of a prior remaining improper no matter how large the sample size is goes as follows: take $\pi(\alpha)=\exp\{\alpha^2\}$ and the sample iid $\mathcal{E}(\alpha)$ [which is equivalent to the normal case when the mean is set to zero since exponential and chi-square distributions are almost the same] The...
Posteriors and Sample Sizes
A simple example of a prior remaining improper no matter how large the sample size is goes as follows: take $\pi(\alpha)=\exp\{\alpha^2\}$ and the sample iid $\mathcal{E}(\alpha)$ [which is equivalent
Posteriors and Sample Sizes A simple example of a prior remaining improper no matter how large the sample size is goes as follows: take $\pi(\alpha)=\exp\{\alpha^2\}$ and the sample iid $\mathcal{E}(\alpha)$ [which is equivalent to the normal case when the mean is set to zero since exponential and chi-square distributi...
Posteriors and Sample Sizes A simple example of a prior remaining improper no matter how large the sample size is goes as follows: take $\pi(\alpha)=\exp\{\alpha^2\}$ and the sample iid $\mathcal{E}(\alpha)$ [which is equivalent
55,093
Power of Meta Regression
The N for the main effect in a meta-analysis is something close to the number of people in all of the studies. That's a lot of people, hence a lot of power. For a meta-regression, the N is much closer to the number of studies, which is a much smaller number. The actual hit in power that you take is a function of the de...
Power of Meta Regression
The N for the main effect in a meta-analysis is something close to the number of people in all of the studies. That's a lot of people, hence a lot of power. For a meta-regression, the N is much closer
Power of Meta Regression The N for the main effect in a meta-analysis is something close to the number of people in all of the studies. That's a lot of people, hence a lot of power. For a meta-regression, the N is much closer to the number of studies, which is a much smaller number. The actual hit in power that you tak...
Power of Meta Regression The N for the main effect in a meta-analysis is something close to the number of people in all of the studies. That's a lot of people, hence a lot of power. For a meta-regression, the N is much closer
55,094
Power of Meta Regression
This is kind of a dogma for meta-analysts, yet there is not much out there. I have researched Google, Google Scholar and PubMed, looking for power, metaregression, meta-regression. These are the items I have found which could be of use: Thompson and Higgins, Statistics in Medicine 2002 Higgins and Thompson, Statistics...
Power of Meta Regression
This is kind of a dogma for meta-analysts, yet there is not much out there. I have researched Google, Google Scholar and PubMed, looking for power, metaregression, meta-regression. These are the item
Power of Meta Regression This is kind of a dogma for meta-analysts, yet there is not much out there. I have researched Google, Google Scholar and PubMed, looking for power, metaregression, meta-regression. These are the items I have found which could be of use: Thompson and Higgins, Statistics in Medicine 2002 Higgins...
Power of Meta Regression This is kind of a dogma for meta-analysts, yet there is not much out there. I have researched Google, Google Scholar and PubMed, looking for power, metaregression, meta-regression. These are the item
55,095
Power of Meta Regression
People usually do a power calculation before starting work to establish the sample size but in meta-analysis the sample size is seldom something you can choose. After the event all the information about precision is contained in the confidence intervals for your coefficients so power is now irrelevant.
Power of Meta Regression
People usually do a power calculation before starting work to establish the sample size but in meta-analysis the sample size is seldom something you can choose. After the event all the information abo
Power of Meta Regression People usually do a power calculation before starting work to establish the sample size but in meta-analysis the sample size is seldom something you can choose. After the event all the information about precision is contained in the confidence intervals for your coefficients so power is now irr...
Power of Meta Regression People usually do a power calculation before starting work to establish the sample size but in meta-analysis the sample size is seldom something you can choose. After the event all the information abo
55,096
XGBoost (Extreme Gradient Boosting) or Elastic Net More Robust to Outliers
1 Yes boosted trees would more easily fit unknown non-linear effects or interactions than regularized linear regression. However, as soon as you are aware of some specific non-linearity you could simply transform data to linearity and continue to use a linaer learner. 2 That depends on how you train the models. If you'...
XGBoost (Extreme Gradient Boosting) or Elastic Net More Robust to Outliers
1 Yes boosted trees would more easily fit unknown non-linear effects or interactions than regularized linear regression. However, as soon as you are aware of some specific non-linearity you could simp
XGBoost (Extreme Gradient Boosting) or Elastic Net More Robust to Outliers 1 Yes boosted trees would more easily fit unknown non-linear effects or interactions than regularized linear regression. However, as soon as you are aware of some specific non-linearity you could simply transform data to linearity and continue t...
XGBoost (Extreme Gradient Boosting) or Elastic Net More Robust to Outliers 1 Yes boosted trees would more easily fit unknown non-linear effects or interactions than regularized linear regression. However, as soon as you are aware of some specific non-linearity you could simp
55,097
Speed up optimization in K-fold cross validation
Warning: this is essentially a non-answer. I your $k$-fold cross validation is to be used for validation purposes, the independence of the optimization is actually crucial. If you use model parameters obtained on the full model for initializing any of the surrogate model trainings, that surrogate model is not independe...
Speed up optimization in K-fold cross validation
Warning: this is essentially a non-answer. I your $k$-fold cross validation is to be used for validation purposes, the independence of the optimization is actually crucial. If you use model parameters
Speed up optimization in K-fold cross validation Warning: this is essentially a non-answer. I your $k$-fold cross validation is to be used for validation purposes, the independence of the optimization is actually crucial. If you use model parameters obtained on the full model for initializing any of the surrogate model...
Speed up optimization in K-fold cross validation Warning: this is essentially a non-answer. I your $k$-fold cross validation is to be used for validation purposes, the independence of the optimization is actually crucial. If you use model parameters
55,098
Speed up optimization in K-fold cross validation
There is a generic framework for improving cross-validation [2]. It does not reuse optimal values obtained on other folds (@cebeleites already mentioned the dangers of such an approach), but instead use relations that may exist between models trained on different datasets and defines the notion of "merging" two models....
Speed up optimization in K-fold cross validation
There is a generic framework for improving cross-validation [2]. It does not reuse optimal values obtained on other folds (@cebeleites already mentioned the dangers of such an approach), but instead u
Speed up optimization in K-fold cross validation There is a generic framework for improving cross-validation [2]. It does not reuse optimal values obtained on other folds (@cebeleites already mentioned the dangers of such an approach), but instead use relations that may exist between models trained on different dataset...
Speed up optimization in K-fold cross validation There is a generic framework for improving cross-validation [2]. It does not reuse optimal values obtained on other folds (@cebeleites already mentioned the dangers of such an approach), but instead u
55,099
Initializing EM algorithm [duplicate]
Here is a self-contained exercise from our book Introducing Monte Carlo methods with R: Consider a sample of size $n$ from a mixture distribution with unknown weights, $$ X_i \sim \theta g(x) + (1-\theta) h(x),\quad i=1, \ldots, > n, $$ where $g(\cdot)$ and $h(\cdot)$ are known. Introduce $Z_1, \ldots, Z_n$, where ...
Initializing EM algorithm [duplicate]
Here is a self-contained exercise from our book Introducing Monte Carlo methods with R: Consider a sample of size $n$ from a mixture distribution with unknown weights, $$ X_i \sim \theta g(x) + (1-
Initializing EM algorithm [duplicate] Here is a self-contained exercise from our book Introducing Monte Carlo methods with R: Consider a sample of size $n$ from a mixture distribution with unknown weights, $$ X_i \sim \theta g(x) + (1-\theta) h(x),\quad i=1, \ldots, > n, $$ where $g(\cdot)$ and $h(\cdot)$ are known....
Initializing EM algorithm [duplicate] Here is a self-contained exercise from our book Introducing Monte Carlo methods with R: Consider a sample of size $n$ from a mixture distribution with unknown weights, $$ X_i \sim \theta g(x) + (1-
55,100
Initializing EM algorithm [duplicate]
You're running a special case of EM for Gaussian mixture models, in which case the most frequently used initialization is k-means. That can be viewed as a kind of "hard-assignment" version of GMM clustering, and so starting from there is typically reasonable. Since you're doing this in one dimension, there are efficien...
Initializing EM algorithm [duplicate]
You're running a special case of EM for Gaussian mixture models, in which case the most frequently used initialization is k-means. That can be viewed as a kind of "hard-assignment" version of GMM clus
Initializing EM algorithm [duplicate] You're running a special case of EM for Gaussian mixture models, in which case the most frequently used initialization is k-means. That can be viewed as a kind of "hard-assignment" version of GMM clustering, and so starting from there is typically reasonable. Since you're doing thi...
Initializing EM algorithm [duplicate] You're running a special case of EM for Gaussian mixture models, in which case the most frequently used initialization is k-means. That can be viewed as a kind of "hard-assignment" version of GMM clus