dialog
listlengths
4
30
title
stringlengths
15
150
category
stringclasses
14 values
dialog_time
stringdate
2016-01-21 01:59:30
2018-07-01 01:34:46
[ { "message": "I'm trying <a href=\"http://scikit-learn.org/stable/modules/generated/sklearn.linear_model.RANSACRegressor.html#sklearn.linear_model.RANSACRegressor\" rel=\"nofollow noreferrer\">Sklearn's RANSAC algorithm implementation to produce a simple linear regression fit with built-in outlier detection/rej...
Sklearn RANSAC linear regression results vary wildly
stats
2018-01-24T18:16:51.747
[ { "message": "I have experimental \"before\" and \"after\" measurements that I need to compare. The standard way in the field is to look at the log ratio, $y = \\log_2(\\frac{a}{b})$, so no change is $0$. I'm trying to find the correct way to calculate the uncertainty for this representation. It's safe here to ...
Propagation of error in log ratios
stats
2018-01-25T03:02:08.110
[ { "message": "Consider a linear model $f(x) = \\phi(x)^\\top w$; where x is deterministic, $\\phi$ is some fixed transformation, $w$ is independent and $w\\sim \\mathcal{N(0, \\Sigma_p)}$. The covariance function is $Cov(f(x),f(y)^\\top) = \\phi(x)^\\top \\Sigma_p \\phi(y)$. Does this imply that the joint dist...
Does a quadratic covariance function imply joint Gaussian distribution?
stats
2018-01-25T08:43:58.403
[ { "message": "<a href=\"https://i.stack.imgur.com/wNtDK.jpg\" rel=\"nofollow noreferrer\">I need advice on fitted functions in the below image. I fitted the below function using a multivariate adaptive regression splines from the <code>earth</code> package in R. <pre><code> fit &lt;- earth(x = pred, y = resp,...
Wrong functions fitted opposite to raw data
stats
2018-01-25T09:42:10.080
[ { "message": "We have a large, nationwide prevalence study about the prevalence of healthcare-associated infections (HAI).<br>We need to see if hospitals have more or less HAI than expected by their patients' characteristics.We estimated the per-patient HAI risk using a conditional tree model with cross-validat...
Using patient characteristics to predict disease and confront with per hospital real cases
stats
2018-01-25T18:26:53.383
[ { "message": "I have five (normalized) variables related to family history of insurance applicants. n = 59,831.I performed a Principal Components Reduction, reduced it to 3 dimensions, put together explains 90.1% variance. When i plot the principal component vectors in 3-D, i get what i can see as 3 clear clust...
Performing clustering after "seeing" that there are 3 clusters on the PCA scatter plot
stats
2018-01-26T06:51:51.413
[ { "message": "My ultimate goal is to be able to have a way to generate a vector of size $N$ of correlated Bernoulli random variables. One way I am doing this is to use the Gaussian Coupla approach. However, the Gaussian Coupla approach just leaves me with a vector:$$(p_1, \\ldots, p_N) \\in [0,1]^N$$Suppose tha...
If I have a vector of $N$ correlated probabilities. How can I turn them into binary $0,1$ without destroying the correlation?
stats
2018-01-26T21:28:45.900
[ { "message": "I am a university student looking for help with analysis for my dissertation, I do not have the best knowledge of R studios or statistics in general so please bear with me!I would like to perform a Poisson Generalized Linear Model (GLM) to see if artificial light had an effect on the number of bat...
poisson glm to observe whether effects of artificial light on the number of bat passes in each location were significant
stats
2018-01-27T15:24:58.153
[ { "message": "When reading about 'Predictive to Prescriptive' analytics, I am not able to find good examples of what it actually means. I know that a <code>predictive</code> model can only tell me <code>what will happen</code>. And in real business scenarios this is not enough. I need to know what can I do to h...
What is prescriptive analytics?
stats
2018-01-27T19:57:27.727
[ { "message": "I am trying to fit a multiple linear regression (OLS) model with IPO underpricing as dependent variable. As part of my master thesis I would like to analyze the effect of venture capital certification (dummy) on IPO underpricing (raw returns - not transformed). My sample consists of 199 IPOs.Up t...
Does the normality assumption hold? Is this an outlier?
stats
2018-01-28T07:15:48.717
[ { "message": "Is there a way to measure how \"predictable\" a dataset is based on some of its inherent attributes such as its entropy level or its amount of self-similarity? If so, how is that \"predictability score\" related to your confidence level of any possible prediction in the future?Allow me to ask this...
How do you measure how "predictable" a dataset is?
stats
2018-01-28T16:58:37.983
[ { "message": "Is there a way to measure how \"predictable\" a dataset is based on some of its inherent attributes such as its entropy level or its amount of self-similarity? If so, how is that \"predictability score\" related to your confidence level of any possible prediction in the future?Allow me to ask this...
How do you measure how "predictable" a dataset is?
stats
2018-01-28T16:58:37.983
[ { "message": "This question is about a kind of bias that is slightly more subtle than doing multiple tests without caution (related to multi-hypothesis testing).Experimenters are willing to reject an hypothesis $H_0$ that a coin is fair, expecting to find a higher probability for heads. When flipping 100 coins,...
Bias caused by optional stopping
stats
2018-01-28T18:51:31.270
[ { "message": "I'm wondering if there is any evidence (simulated or otherwise) demonstrating that robustness to specification actually means a result is more likely to be true. By robustness to specification I mean that a particular relationship is found to be significant (e.g. gun ownership increases suicide) ...
Does having a result that is "robust to specification" make it more likely to be true?
stats
2018-01-29T16:09:46.280
[ { "message": "I have been thinking about the following question recently. As an econometrics major I'm not sure how to answer this properly. When trying to predict a time series data, one of the first things you look into is mean stationarity, the data shouldn't have any trend in order to make accurate predicti...
Stationarity: time series vs regression
stats
2018-01-29T19:52:53.063
[ { "message": "I see sometimes people using two different ways to specify the random effects when conducting multilevel modelling with <code>lme4</code> in R.<pre><code>model1 &lt;- lmer(fix1 + (1|cluster1), data = dat)model2 &lt;- lmer(fix1 + (1|fix1:cluster1), data = dat)</code></pre>Judged by my limited knowl...
Difference between `fix1 + (1|cluster1)` and `fix1 + (1|fix1:cluster1)` when specifying random intercept using lme4 in R
stats
2018-01-30T01:34:24.047
[ { "message": "Suppose you have observations which, over the observed range of outcomes, are well-fitted by some distribution like the Pareto that, for certain parameter values, has a an infinite variance. For example, the famous (but not especially accurate) \"80/20 law\" implies a tail index of about 1.16, we...
If the best-fitting distribution has infinite variance, should low observed variance be troubling?
stats
2018-01-30T05:23:29.887
[ { "message": "This is my first post &amp; I'm fairly new to GAMs; apologies.I ran a series of 16 generalized additive negative binomial models (gam, family=nb, mgcv package) with increasing complexity that modeled the abundances of 12 fish species (independently) as functions of several environmental metrics (a...
GAM (mgcv): AIC vs Deviance Explained
stats
2018-01-30T10:38:39.660
[ { "message": "I am working with an unbalanced data set where most subjects have only 1 observation, but many have >1. When I fit a linear mixed model to these data (random intercept), there is a strong pattern in the residuals vs. fitted. I was able to duplicate the problem with simulated data (below). <a hr...
Strong linear pattern in residuals of random intercept model (simulated unbalanced data)
stats
2018-01-30T16:46:39.203
[ { "message": "I have the following regression$$y_i=a+bx_i+cz_i+dw_i$$a, b, c, d are coefficients. x is endogenous.z and w are exogenous to errors. My question:What parameters could be adjusted to vary the severity of the endogeneity problems in the regression?", "role": "user" }, { "message": "Let's...
to vary the severity of the endogeneity problems
stats
2018-01-30T23:10:55.427
[ { "message": "I'm learning statistics with SPSS. I have a test case where I need to analyze using regression linear method, I'm not sure if I can explain clearly so please refer to the picture. My understanding is to define the input into multiple-response set and then analyze the set using the regression linea...
How should I model relationships among latent variables
stats
2018-01-31T05:23:48.587
[ { "message": "I have four years of monthly data, but I want to use three years to test the forecast of a model which uses only one year of historical data in a rolling way. For example:historical data from Jan-2016 to Dec-2016 will be used to forecast Jan-2017 to Dec-2017but then Feb-2016 to Jan-2017 data will ...
Can MASE be used with a rolling forecast?
stats
2018-01-31T14:43:17.367
[ { "message": "I'm looking for some references on the following problem. You're given a pre-trained classifier network, say ResNet-50, on images that are 255x255, from which you can extract the last fully connected layer (2048 dimensional) to get features. The goal is to then leverage the pre-trained model for a...
Applying pre-trained Convolutional Neural Nets on large images
stats
2018-02-01T02:03:45.587
[ { "message": "I am a newbie to Xgboost and I would like to use it for regression, in particular, car prices prediction. I started following a tutorial on XGboost which uses XGBClassifier and objective= 'binary:logistic' for classification and even though I am predicting prices, there is an option for objective ...
XGBClassifier and XGBRegressor
stats
2018-02-01T07:05:51.967
[ { "message": "Suppose I want to sample from a continuous distribution $p(x)$. If I have an expression of $p$ in the form$$p(x) = \\sum_{i=1}^\\infty a_i f_i(x)$$where $a_i \\geqslant 0, \\sum_i a_i= 1$, and $f_i$ are distributions which can easily be sampled from, then I can easily generate samples from $p$ by:...
Exact Sampling from Improper Mixtures
stats
2018-02-01T21:28:48.310
[ { "message": "My data set focuses on the percentage cover of plants within quadrats at different locations. An example of my data looks like this:<pre><code>Quadrat_Number Cover(%) Mean_Cover(%) 1 10 2.5 2 15 3.75 3 5 1.25 4 12 ...
Standard deviation of the Mean
stats
2018-02-02T11:41:26.630
[ { "message": "I am developing a random forest for a binary classification problem where the trained data is heavily skewed towards one class (90% is class A and 10% is class B). The model scores data points based on their likelihood to be of class A, i.e., the number of trees in the forest that classify the dat...
Effects of selection bias in training data introduced by previous model outputs
stats
2018-02-02T15:02:16.717
[ { "message": "I have a question regarding the hypothesis of the distribution of the dependent variable in a linear regression model. I have a model to assess the earning losses of displaced workers. I have observations of treated (displaced) and control (non displaced) workers. When a worker is displaced and on...
Distribution of dependent variable in linear regression with fixed effect (panel data)
stats
2018-02-02T15:15:17.347
[ { "message": "I am given a financial time series that is characterized by a bunch of structural breaks, i.e. the series isn't moving (literally at all), but at some points in time the series jumps up or down. Then it stays at this level for a while until the series jumps again. So the time series basically look...
time series mainly characterized by structural breaks - how to model?
stats
2018-02-02T17:11:15.760
[ { "message": "I have some data to which I'd like to fit a GLM using PyMC3. Here are the posterior predictive regression lines plotted along with the data points:<a href=\"https://i.stack.imgur.com/uHh7d.png\" rel=\"nofollow noreferrer\">Domain knowledge indicates that a linear model with zero-intercept is appro...
Posterior predictive regression lines in Bayesian linear regression seem to exclude most data points
stats
2018-02-02T18:31:25.103
[ { "message": "Consider the simple regression model $y = a x + b + \\varepsilon$, where $x$ is a covariate, $y$ is the observed response and $\\varepsilon$ is the unobserved noise (with no distribution assumption). We can add to the model a covariate $\\omega$ which is a realisation of a gaussian noise, and this...
Mean adjusted $R^2$ for linear regression with gaussian noise covariates
stats
2018-02-03T01:11:36.117
[ { "message": "I have three separate datasets that I would like to fit separate analytic distributions to. Disclaimer, I am a physicist so I don't have too thorough background in statistics, and so I am basically wondering (a) whether it is possible to fit any analytic functions to these data, especially for the...
Choosing Analytic Functions to Fit to Data
stats
2018-02-03T08:07:37.643
[ { "message": "While trying Gaussian Mixture Models <a href=\"http://scikit-learn.org/stable/modules/generated/sklearn.mixture.GaussianMixture.html\" rel=\"noreferrer\">here, I found these 4 types of covariances. <pre><code>'full' (each component has its own general covariance matrix),'tied' (all components shar...
Different covariance types for Gaussian Mixture Models
stats
2018-02-03T18:55:20.280
[ { "message": "I have an operations research problem that I would like to solve but I am unsure what the correct framework for analyzing it would be. The closest I've come across so far is contextual bandits I believe but I don't know enough to know for sure.Here is the problem:How to efficiently get rid of inve...
Is this a contextual bandit problem?
stats
2018-02-03T19:18:24.180
[ { "message": "I'm trying to visualize correlation matrices using heatmaps. However, the results can be unsightly and seem unstructured. I give an example below (blue is positive correlation, red is negative).$\\hspace{4.5cm}$<a href=\"https://i.stack.imgur.com/JuEGq.png\" rel=\"nofollow noreferrer\">How could I...
Visualizing correlation matrices and reducing their bandwith
stats
2018-02-04T01:08:47.500
[ { "message": "I am trying to understand why should there be different distribution for t-statistic, in case of AR model, Dickey-Fuller test For e.g. Say, the model is $Y_t = \\beta_lY_{t-1} + \\varepsilon_{t}$.Why should I not use Simple linear regression model like $y_i = \\beta_0 + \\beta_1x_i+\\epsilon_i$, ...
Why is the dickey fuller test different from a simple t-test
stats
2018-02-04T09:26:33.690
[ { "message": "I am doing VAR analysis of 5 years long data. It is hourly data, so 1~24 hours every day and this goes on for 5 years. I heard it is good to choose 4 lag length for quarterly data and 12 for monthly data. But I do not know what to choose for 'daily data'.Can you guys help me out on this?Thank you....
How many lags for a VAR model for hourly data?
stats
2018-02-04T17:12:29.303
[ { "message": "I am rolling a fair die. What is the probability distribution of number of rolls until I first accumulate either:1) Five ones2) 20 occurrences of faces that are not one?I'm happy to share the actual application if that would help.", "role": "user" }, { "message": "You are performing t...
Competing negative binomials
stats
2018-02-04T22:28:40.653
[ { "message": "From elementary probability course, the probability distributions such as Gaussian, Poisson or exponential all have a good motivation. After staring at the formula of the <a href=\"https://en.wikipedia.org/wiki/Exponential_family\" rel=\"noreferrer\">exponential family distributions for a long tim...
What is the rationale behind the exponential family of distributions?
stats
2018-02-04T22:55:27.513
[ { "message": "I am working on my thesis but I am stuck on the last task to solve.STEP 1) I have a dataset composed of three variables:<code>fidelity_card_ID</code>: fidelity card associated to the purchases<code>shopping_date</code>: day when the purchases were made<code>cluster</code>: express the pattern of t...
Detect anomalies in customers behaviour based on their specific recurrent patterns of shopping
stats
2018-02-05T11:35:21.217
[ { "message": "I'm working on a dataset which is giving me trouble. I have 200 samples (Sample 1, Sample 2...). An example dataset (limited to 15 samples) is <a href=\"https://www.dropbox.com/s/8m3tfv78nh18k83/Dataset%20example%20for%20stackoverflow.xlsx?dl=0\" rel=\"nofollow noreferrer\">here. My dataset is st...
Analysis of a dataset including dichotomial, ordinal and % data
stats
2018-02-05T17:41:25.493
[ { "message": "I am new to the machine learning field, but I wanted to try and implement a simple classification algorithm with Keras. Unfortunately, I have a very small set of data, so I thought to try to apply transfer learning to the problem; however, I couldn't find anything on this online, so I wanted to un...
Where to find pre-trained models for transfer learning
stats
2018-02-06T07:33:02.347
[ { "message": "Is there any possibility in R to get a list of distances between all the points in a Scatterplot? For instance, this Scatterplot:<a href=\"https://i.stack.imgur.com/scm3e.png\" rel=\"nofollow noreferrer\">So, I would like to obtain a list of distances among all the points.", "role": "user" }...
Distance between all the dots in a scatterplot in R
stats
2018-02-06T12:29:59.370
[ { "message": "What do people do when you perform GMM to cluster and the result comes to out to be a bimodal distribution. However, one cluster is broad enough that it includes the other cluster and this results in a situation where the very end of the broader cluster may fit observed data better than the smalle...
Gaussian Mixture Model (GMM) has a maximum likelihood when two clusters one includes the other
stats
2018-02-06T15:49:36.333
[ { "message": "I have a dataset of total number of Vehicles Registered for 16 years. These are a total of 16 values from 2001-2016. Which Machine Learning Technique would be best for predicting the number of vehicles in the upcoming years - say till 2050 - while using R ?This is my Dataset:-<pre><code> D...
Predict Values based on 16 values of Past 16 years
stats
2018-02-06T15:54:39.640
[ { "message": "I've read a few Q&amp;As about this, but am still not sure I understand, why the coefficients from glmnet and caret models based on the same sample and the same hyper-parameters are slightly different. Would greatly appreciate an explanation!I am using caret to train a ridge regression:<pre><code>...
r: coefficients from glmnet and caret are different for the same lambda
stats
2018-02-07T00:29:41.257
[ { "message": "What situations do we know of where gradient descent can be shown to converge (either to a critical point or to a local/global minima) for non-convex functions? For SGD on non-convex functions, one kind of proof has been reviewed here, <a href=\"http://www.cs.cornell.edu/courses/cs6787/2017fa/Lect...
Gradient descent on non-convex functions
stats
2018-02-07T02:50:17.093
[ { "message": "I have been trying to understand how to represent and shape data to make a multidimentional and multivariate time series forecast using Keras (or TensorFlow) but I am still very unclear after reading many blog posts/tutorials/documentation about how to present the data in the correct shape (most e...
Multi-dimentional and multivariate Time-Series forecast (RNN/LSTM) Keras
stats
2018-02-07T14:04:12.113
[ { "message": "Suppose that I have two or more groups of data (e.g. two or more cities with 10 sampled population each) and I want to test if they behave differently for a variable (e.g. specific crime) through the years.Is it correct if I run one way ANOVA or Kruskal-Wallis at each of the time points? I guess t...
Can I run one way ANOVA at each of my time points?
stats
2018-02-07T18:36:06.133
[ { "message": "Say I have a sample population A it has mean $\\mu_A$. I sample A and obtain another sample population $\\hat A$, it has a mean of $\\mu_\\hat A$.If a hypothesis test indicates that I should be 95% confident that the two means $\\mu_A$ and $\\mu_\\hat A$ are not equal.What can I infer about $\\ha...
mean of sample vs the sample mean
stats
2018-02-08T01:24:34.117
[ { "message": "I have a time-series data containing 27 values (of no. of Vehicles) from 1990 to 2016. I wanted to predict - based on the underlying trend - the values upto 2050 (which is a long shot I agree).Upon doing some research, I found that it can be done by methods like HoltWinters or TBATS which, even th...
Right Way to Extrapolate Data
stats
2018-02-08T03:11:32.857
[ { "message": "This question has been asked several times on this website. But the problem is that all the references suggested are mathematics oriented and difficult to understand. I am looking for a reference, which explains it in easy language but without over-simplifying. I want to understand the basic ideas...
Reference Request for Fractional Brownian motion
stats
2018-02-08T04:31:59.027
[ { "message": "A reviewer asked me to do multiple comparisons corrections for two-way and three-way interactions that showed significance in my manuscript. I did my data analysis with linear mixed model in R. I had three different tasks for the same participants. Among 3 tasks, the other 3 outcomes were drawn fr...
multiple correction comparisons (Interactions)
stats
2018-02-08T17:10:47.183
[ { "message": "Suppose there are two samples A and B. A has average $u_{1}$ and standard deviation $s_{1}$, B has average $u_{2}$ and standard deviation $s_{2}$. We know they come from two independent normally distributed population. How do we find the joint confidence interval ($\\alpha$) for both of the popul...
How to find joint confidence interval for a bunch of normal distributed samples
stats
2018-02-08T17:30:24.600
[ { "message": "I have a set of 35 independent variables (features). I do not have response variable for my data set. I used density plots to identify multi-modal distribution in my independent variables. Hence, I used Gaussian mixture clustering technique to group the data. Upon clustering, I obtained 6 clusters...
What statistical test for cluster analysis results should I use?
stats
2018-02-08T21:24:36.937
[ { "message": "Let's say I have a text classifier that I have trained on some training dataset. Now when I run this trained classifier on some test dataset, I identify the cases where it went wrong (assuming I have correct labels for test dataset as well). How can I re-train the classifier such that it learns fr...
Learning from Mistakes in a classification task
stats
2018-02-08T22:13:01.537
[ { "message": "Consider a covariance function of the form$$K_{i,j}=\\alpha\\times exp(-0.5 (x_i-x_j)^2/l^2)$$This is a very common function used in Gaussian processes. How to show that this covariance is non-negative definite ?", "role": "user" }, { "message": "I am not an expert but I'll sketch a s...
Prove that the squared exponential covariance is non-negative definite
stats
2018-02-08T22:20:54.223
[ { "message": "I am doing semantic segmentation (multi-class classification of image pixels) using convolutional neural networks (CNN) in Keras.In particular, I am applying this to aerial images of crops (vegetation). In Keras, I successfully developed a workflow to segment/classify different crops for one speci...
How can I train my deep learning model on another similar yet different dataset
stats
2018-02-08T22:54:31.007
[ { "message": "200 Participants completed 3 tasks (easy, medium, difficult) and a cognitive ability test. All variables are continuous (for the task I have the time it took each participant to complete each task, and the cognitive test's score). To sum, I have 1 within variable (task difficulty) and 1 between va...
Repeated measures or Mixed Models?
stats
2018-02-09T04:54:11.937
[ { "message": "Let's say the mean income in New Jersey (group 1) and Florida (group 2) is $80,000 and $55,000 respectively. Using a dataset of relevant predictor variables, I'd like to attempt to explain this gap (i.e. $25,000). My question is what method I'd use to do so. For example, would I take the differenc...
What method can I use to account for differences in group means?
stats
2018-02-09T22:03:46.917
[ { "message": "I have a time series that is quite erratic, having lots of small increases and then large drops. I want to see if the mean is statistically significantly different to zero. Using a t-test, I get a p-value of around 0.6, but using a wilcoxon ranksum test I get a p value of 0.0001. How is this possi...
t-test vs Mann–Whitney U test strongly differ in p-value
stats
2018-02-11T18:39:55.100
[ { "message": "I have created composite variables after a factor analysis. The original variables were categorical (levels 1-7) and the composites were created by averaging the items loading into each factor.I decided to round the new variables resulting from the averages to the nearest units. It seemed logical,...
Impact of rounding a variable to the nearest unit
stats
2018-02-11T19:07:09.240
[ { "message": "This is an exercise I am stuck on.Given an IID sample $X_1, \\dots, X_n \\sim N(\\mu, \\sigma^2)$ with $\\mu \\ne 0$ let$$S_n^2 = \\frac{1}{n} \\sum_{i = 1}^n ( X_i - \\overline{X_n})^2$$be the sample variance and $\\overline{X_n}$ the sample mean. I am tasked in finding the asymptotic distributio...
On finding the asymptotic distribution of the sample variance using the delta method
stats
2018-02-12T10:26:42.783
[ { "message": "I have a problem with a time series. In short: How do I detrend a time series with a break and some big outliers?Long version: I want to detrend a time series into a trend and some cyclical components. The time series looks like this:<a href=\"https://i.stack.imgur.com/5rlhn.png\" rel=\"nofollow n...
Detrending a nice series with dummys and a break
stats
2018-02-12T16:51:00.560
[ { "message": "I am attempting to build a model which, for a patient currently admitted to the hospital, predicts the remaining amount of time until the patient is discharged.Some of the predictors I'd like to use are patient-level (e.g. ethnicity), others are admission-level (e.g. admission diagnosis), and othe...
How to model remaining hospital length of stay?
stats
2018-02-12T21:56:02.790
[ { "message": "I read Neil's <a href=\"http://inverseprobability.com/talks/slides/2017-12-04-deep-probabilistic-modelling-with-gaussian-processes.slides.html\" rel=\"nofollow noreferrer\">presentation and found this joint model is confusing:$$p(y_*|y, X, x_*) = \\int p(y_*|x_*, W)p(W|y, X)dW $$where $W$ contains...
Probabilistic model of neural network
stats
2018-02-13T04:09:45.453
[ { "message": "I searched about Bayesian Ridge Regression on Internet but most of the result i became is about Bayesian Linear Regression. I wonder if it's both the same things because the formula look quite similar", "role": "user" }, { "message": "<a href=\"http://scikit-learn.org/stable/modules/li...
Is Bayesian Ridge Regression another name of Bayesian Linear Regression?
stats
2018-02-13T10:21:09.080
[ { "message": "I've seen similar questions posted elsewhere with no answer, so I thought I'd put this out into the CrossValidated universe. I am attempting to do a Tukey's post-hoc test on a model that has an interaction. To do this, I have used the <code>interaction()</code> function to create a new variable th...
Tukey with interaction and extracting letters in multcomp
stats
2018-02-13T21:32:32.620
[ { "message": "In ranking, a commonly used method to evaluate the performance of a ranking algorithm is calculating ranking metrics such as MAP, NDCG. In use cases where there is no ground truth signal, some proxy signals as used for relevance. For example, in a recommendation system, we can use user's interacti...
Remove bias in ranking evaluation
stats
2018-02-14T01:51:20.780
[ { "message": "This is my question: I have to perform a mini-meta-analysis on two studies(independent, balanced sample) with a Repeated measures design and with two within factors. I have the F statistic and the p value of two significant interactions in study 1 and study 2. I want to present a unique p value, s...
Stouffer method
stats
2018-02-14T09:02:07.580
[ { "message": "I have been playing around with using restricted cubic splines using the RMS package. Output below.<pre><code>library(rms) nlmodel_ni_bi_4 &lt;- lrm(outcome~ rcs(age,4) + ethnicity + AV + sex + nb, data=df)nlmodel_ni_bi_4Frequencies of Missing Values Due to Each Variable outcome ...
Reporting the effect of a predictor in a logistic regression fitted with a restricted cubic spline
stats
2018-02-14T09:59:25.303
[ { "message": "Standard teaching says that sensitivity and specificity are properties of the test and are independent of prevalence. But isn't this just an assumption?Harrison's principles of internal medicine 19th ed says<blockquote> It has long been asserted that sensitivity and specificity are prevalence-ind...
Is sensitivity or specificity a function of prevalence?
stats
2018-02-14T10:35:39.930
[ { "message": "Standard teaching says that sensitivity and specificity are properties of the test and are independent of prevalence. But isn't this just an assumption?Harrison's principles of internal medicine 19th ed says<blockquote> It has long been asserted that sensitivity and specificity are prevalence-ind...
Is sensitivity or specificity a function of prevalence?
stats
2018-02-14T10:35:39.930
[ { "message": "Consider a good old regression problem with $p$ predictors and sample size $n$. The usual wisdom is that OLS estimator will overfit and will generally be outperformed by the ridge regression estimator: $$\\hat\\beta = (X^\\top X + \\lambda I)^{-1}X^\\top y.$$ It is standard to use cross-validation...
Is ridge regression useless in high dimensions ($n \ll p$)? How can OLS fail to overfit?
stats
2018-02-14T16:31:47.080
[ { "message": "One of the things that make them super-slow in training, is that they often use two nested loops to iterate on data through all time steps for every single iteration, calculating loss and cost at the end, and then back-propagate that error to get the gradients to update all weight matrices.I mean,...
Why this Way of iteration in RNNs?
stats
2018-02-14T19:57:11.913
[ { "message": "I am conducting a meta-analysis and I am extracting pearson's correlation coefficient (r) from studies in order to meta-analyse them. Some studies have not used correlations so I am having to calculate r from the statistics they report. One study has reported a logistic regression, is it meaningfu...
Can I squareroot r2 to get r in a logistic regression?
stats
2018-02-15T19:46:43.603
[ { "message": "I'm trying to model a future balance for any time <code>t</code> in a list of bank accounts.I have historical balance &amp; transactional data, and other factor data that affects the balance of an account (such as interest payments, fees, etc) that I'll try to fit in the model as well.My question ...
Volatility Modeling what's the right approach? / Time Series predictive modeling of future balance in a bank account
stats
2018-02-16T14:25:42.207
[ { "message": "I was reading a paper about variance reduction techniques, where they want to create a valid correlation matrix of size $n \\times n$, but with the same pairwise-correlation coefficient, therefore, every off-diagonal entries are set to the same number $\\alpha$:$$ R_n = (r_{ij}) =\\begin{pmatrix} ...
Condition for valid correlation matrix with constant pairwise-correlation
stats
2018-02-16T18:33:31.337
[ { "message": "I'm trying to figure out how to calculate clustered standard errors via boostrap when the clusters are nested. I know that when there is a single level of clustering, you sample at the cluster level rather than at the individual level. Any idea what you do when there are multiple nested levels?To ...
Calculating nested clustered standard errors with bootstrap
stats
2018-02-16T18:54:56.693
[ { "message": "When I run a regression with an interaction term (composed of one continuous variable and one binary variable) and several covariates, I get an interaction term value of -6.52. However, when I run two separate regressions for each value of the binary variable, the coefficients of the predictors ar...
Moderated regression and separate models give slightly different results
stats
2018-02-16T19:32:15.053
[ { "message": "Adaboost is an ensemble method that combines many weak learners to form a strong one. All of the examples of adaboost that i have read use decision stumps/trees as weak learners. Can i use different weak learners in adaboost? For example, how to implement adaboost (generally boosting) to boost a l...
Boosting A Logistic Regression Model
stats
2018-02-16T20:39:09.590
[ { "message": "Consider a MA system $$y[k] = x[k]+a_1*x[k-1] + a_2*x[k-2] + a_{9}*x[k-9] + n[k] \\tag{1}$$ where $n \\sim N(0,\\sigma^2)$ is Additive White Gaussian Noise and $x$ is a zero mean Gaussian white process of unity variance. In this model only 3 coefficients are non-zero whereas the rest are all zero ...
Can `l1` minimization be solved in Matlab using `fmincon`?
stats
2018-02-18T04:48:00.500
[ { "message": "Is simultaneity the same as heterogeneity? Are both sources of endogeneity and hence bias? As far as I understand, simultaneity bias arises when both variables are determined from within the model where as heterogeneity bias is differences across observational units which causes the error term to ...
Sources of Endogeneity
stats
2018-02-18T10:08:25.600
[ { "message": "In class we've seen that $a$ (the weights) must satisfy $$X^T (y-Xa) =0$$Here $X$ is a $(n\\times d)$ matrix (so we have $n$ samples in $\\mathbb R^d$)let's denote the residuals $r = y-Xa$. In our class notes, it is written that<blockquote> The normal equations require the residuals to be orthogo...
Understanding linear regression
stats
2018-02-18T17:38:44.103
[ { "message": "My data set contains around 630,000 rows and the data set looks like this:date site code latitude longitude rollingo3 rollingpm2.5 1 2015-01-01 17:00:00 Aberdeen ABD 57.2 -2.09 58.5 5.96<br>2 2015-01-01 18:00:00 ...
How can I cluster the following data set to find out the time when ozone and pm level are high in different stations using R?
stats
2018-02-18T20:42:16.850
[ { "message": "If I know the functional form of a distribution, is it better to fit the distribution to the data to find the mean, or is it better to just look at sample average.I know sample average is the unbiased estimator of the mean, but I feel like fitting to a known distribution may reduce the effect of o...
Average from distribution-fit vs sample average
stats
2018-02-18T22:26:31.223
[ { "message": "I have been working on a Network-based clustering approach. I used \"cluster_optimal\" of 'igraph' package in R for clustering. The function works by modularity maximization algorithm. I have understood the concept of modularity (Newman, 2006). But I could not understand how modularity maximizati...
Clustering network usign modularity maximization algorithm
stats
2018-02-19T01:52:08.760
[ { "message": "I have some count data of advanced stage juvenile snails in tanks that are sampled every 4 days for 4 sample points. I want to see how much the snail development stages change with a changing dosage of algae (3 tanks per dosage). So the number of advanced juvenile snails (a proportion of the tota...
Accounting for time in repeated measures glmm, R
stats
2018-02-19T02:40:32.033
[ { "message": "I have a question regarding one part in section 4.5.2. Specifically conclusions about equation (4.148):$$p(a)=\\int \\delta(a-\\mathbf{w}^T\\phi)q(\\mathbf{w})\\mathrm{d}\\mathbf{w}.$$I think context is not that important, the only relevant thing is that $a$ is projection of $w$ on $\\phi$. So the...
Predictive distribution derivation from Bishop "Pattern Recognition and Machine Learning "
stats
2018-02-19T08:00:23.597
[ { "message": "I am reading this tutorial <a href=\"http://math.arizona.edu/~jwatkins/f-transform.pdf\" rel=\"nofollow noreferrer\">http://math.arizona.edu/~jwatkins/f-transform.pdf which explains transformations of random variables.It says that the PDF of a transformed random variable $Y = g(X)$ can be found ea...
PDF of a transformed variable; what if $g(x)$ is not increasing but $g^{-1}(x)$ is?
stats
2018-02-19T08:20:20.107
[ { "message": "How do we determine when to use a Logistic Regression or a SVM considering the dependent variable is categorical? What are the conditions we need to look at before deciding the either of the two?", "role": "user" }, { "message": "The main difference is that logistic regression can only...
Logistic Regression Vs SVM
stats
2018-02-19T08:21:20.593
[ { "message": "I’m training some supervised machine learning algorithm to perform the prediction of a continuous variable. I’m currently applying a nested cross-validation protocol (inner: LOOCV; outer: LOOCV; sample). It is a pilot and I have only 70 cases at the moment, while a test may come later if the pilot...
Is there a general and model-independent way of calculating prediction intervals in machine learning for regression task?
stats
2018-02-19T17:14:39.220
[ { "message": "I'm working on the following problem:<blockquote> When applying for a secretarial position, $n$ candidates line up in random order for interviews, where the manager after each interview has to decide to take or decline that candidate. His assessment is qualitative in the sense that at interview $...
Understanding simulation in the secretary problem
stats
2018-02-19T17:40:45.337
[ { "message": "I want to test whether the coefficients of two independent variables ($x_1, x_2$) are different in two groups.I know I can use a dummy variable $d$ which equals $1$ for group $1$ and equals $0$ for group $2$, and then get the regression model $y=β_0+β_1d+β_2x+β_3xd$ to see whether $β_3$ significan...
How to compare the regression coefficients of two independent variables between two groups
stats
2018-02-19T23:26:57.837
[ { "message": "I've read a number of the other discussions I can find on here about lower order items and interaction terms in regression but either my statistical incompetence is preventing from seeing it or I could not find a clear answer to the specific question I have. Any help would be very much appreciated...
How to report a multiple linear regression equation when the interaction makes lower order items non-significant
stats
2018-02-20T12:13:11.837
[ { "message": "I'm doing some analyses in which I have 1 continuous independent variable (IV) and 1 dichotomous independent variable (IV2) that's a demographic covariate. I'm now realizing that they are extremely correlated (~ .9). See image below.<a href=\"https://i.stack.imgur.com/mLhcL.png\" rel=\"nofollow no...
Analyses when IVs highly correlated - is there anything I can do?
stats
2018-02-20T13:03:02.163
[ { "message": "I am using propensity score matching with kernel matching to test for the average treatment effect on the treated. <a href=\"https://i.stack.imgur.com/GR0oh.png\" rel=\"nofollow noreferrer\">The distribution of the bootstrapped differences is as follows:<a href=\"https://i.stack.imgur.com/mtcb9.pn...
BCa confidence interval and p-value disagreement. What coefficient to be reported?
stats
2018-02-20T14:31:02.850
[ { "message": "I am fairly new to R was wondering if this approach was appropriate. Sorry if I forget anything in my question.I have long-form panel data for 15 years (2001-2015) for hundreds of counties and corresponding BEA linecode data for each of these counties (i.e., personal income, employment, etc). For ...
Is a Chow test appropriate for this intervention analysis?
stats
2018-02-20T16:02:23.010
[ { "message": "I know that you want to use principal component analysis when you believe that the independent variables are correlated with each other. But someone told me that if you do not have enough data, it is not worth it, and I do not really know why.My current data has about 80 rows and 17 columns, so 80...
What size of data is good to use principal component analysis?
stats
2018-02-21T03:08:07.843
[ { "message": "I am looking for the maximum likelihood estimator (MLE) for the <a href=\"https://en.wikipedia.org/wiki/Poisson_binomial_distribution\" rel=\"nofollow noreferrer\">Poisson-binomial distribution. I understand the derivation of the MLE for a <a href=\"https://math.stackexchange.com/questions/214220...
MLE for Poisson-binomial distribution
stats
2018-02-21T04:24:27.160