All Questions

-1
votes
0answers
15 views

ggsave gives blank jpeg image [migrated]

I am trying to save my plots in my R script. I used the following context: ...
1
vote
0answers
12 views

Randomized Block Design Models

I have been asked to fit the following models in R: The models are based on this data: I know the mediums are the blocks and the units of the active ingredient are the treatments. I understand how ...
0
votes
0answers
6 views

If one has a sequence of possible MC chains, but they are independent, then what does “expectation of the entire set of outcome sequences” mean?

If one has a sequence of possible MC chains, but they are independent, then what does "expectation of the entire set of outcome sequences" mean? E.g. for a 1-length chain one may have: 1->2 with p=1/...
2
votes
1answer
64 views

Learning a quadratic function using TensorFlow/Keras

Heads up: I'm not sure if this is the best place to post this question, so let me know if there is somewhere better suited. I am trying to train a simple neural network to learn a simple quadratic ...
0
votes
0answers
14 views

How to understand bayesian inference in the framework of deeplearning?

It is said that $p \left( \theta | y _ { 1 : N } \right) \propto _ { \theta } p \left( y _ { 1 : N } | \theta \right) p ( \theta )$. And $p \left( \theta | y _ { 1 : N } \right)$ is the posterior, $ ...
1
vote
0answers
13 views

How to fix this error p<0! while optimizing SVM using PSO? [on hold]

I am trying to optimize SVM paramters for a regression problem using PSO in R. I am getting this weird error. Any suggestion on how to fix this error would be greatly appreciated. Error in svm....
0
votes
1answer
14 views

What is the corresponding model when I include drift in an SARIMA model with seasonal differences?

I fitted the following model, but I am not sure if the drift term is an intercept term or the mean of $y_t-y_{t-4}$ (as it seems in a blog post by Rob Hyndman). ...
0
votes
1answer
23 views

Dealing with missing month values in dataset and plotting a time series

So i currently have a dataset in R: ...
3
votes
1answer
135 views

In the presence of heteroskedasticity, is quantile regression more appropiate than OLS?

..for understanding the relationship between a dependent and independent variables, given that quantile regression makes no assumptions about the distribution of the residual.
0
votes
0answers
6 views

MDS for word vectors: Weighting and distance measures

I calculated a Latent Dirichlet Allocation (LDA) based customer reviews for three different smartphone brands. The topics represent the attributes of the brands. I want to map the single topics on an ...
6
votes
2answers
286 views

lm and glm function in R

I was running a logistic regression in r using glm() as glm(Y ~X1 + X2 +X3, data = mydata, family = binomial(link = "logit")) ...
0
votes
0answers
8 views

What SPSS tests do I use to compare both continuous and categorical motivations - all of them tested with all of them

I created a table of Spearmans correlation for the continuous Likert scale motivations - which was great. I have compared them against each other (I believe this is correct?), as it was displayed on a ...
1
vote
1answer
23 views

linear mixed model: visualising fixed effect and interaction with continuous variable (with confidence interval)

My aim is to analyse the blood concentration of a biomarker and its annual increase in four different subject groups using longitudinal measurements, i.e. biomarker concentrations of each subject were ...
0
votes
0answers
14 views

How to interpret plot residuals vs fitted values?

I run a ols regression and want now check the linearity assumption. I found out that i have to plot the residuals vs the fitted values and if there is no non linear pattern the linearity assumption ...
0
votes
1answer
20 views

Why the dependent variable as a time series in GAM should be log transformed?

I found in Section 3.1 of this paper (see ), the author used log(y) due to "the context of a concentration time series". A book (Hastie and Tibshirani, 1990) is cited, however I cannot get this book. ...
0
votes
0answers
4 views

Piecewise Pareto Distribution

What are the best practices for Piece-wise Pareto Distribution or maybe Pareto Mixture Model(?). Example: $x\in [0, 1) \Rightarrow \alpha=0.1$ $x\in [1, 10) \Rightarrow \alpha=0.5$ $x\in [10, 100) ...
1
vote
1answer
31 views

Convergence of error term

I was deriving the ratio of a Laplace approximation with the true quantity and I got this: $$ \left(n\bar{x} + \alpha - \frac{1}{2}\right)\log\left(\frac{\bar{x}+(a-1)/n}{\bar{x}+\alpha/n}\right) + n\...
0
votes
0answers
8 views

Is it okay to compare Test BLEU score between NMT models while using a slightly modified standard test sets?

I am using tst2013.en found here, as my test sets to get the Test BLEU score to compare to other previous models. However, I have to filter out some sentences that ...
0
votes
0answers
8 views

Can multi-variate Gaussian be used to get Bayesian probability distribution? [on hold]

Question There is a bi-variate Gaussian distribution and fix x1 to X1. Is the distribution of p(x2) with X1 can be said as the Bayesian probability distribution p(x2|X1), apply re-normalise if ...
0
votes
0answers
7 views

Wilks' lambda's exact distribution when one of the parameters is 1 or 2

Citing Wikipedia, From the relations between a beta and an F-distribution, Wilks' lambda can be related to the F-distribution when one of the parameters of the Wilks lambda distribution is either 1 ...
0
votes
0answers
12 views

Forecasting with time series with different interval

I am trying to forecast monthly inflation rates using weekly percentage change of commodities prices. Is there a way to do this without losing info? or can I like get the predictor's moving average ...
0
votes
1answer
17 views

Cohen's kappa for agreements between two inter rater metrics?

I have two metrics for measuring source code cohesion. To verify that both have some agreement can I use Cohen kappa for that? Both the metrics have values in range [0 to 1]. It's not necessary if ...
0
votes
0answers
15 views

Variable importance Plot for a categorical variable in R [on hold]

The input variables for training random forest algorithm are given in the table. From the research article Random forest based hourly building energy prediction In that day type, workday type and time ...
0
votes
0answers
18 views

Distribution of Median in iid Uniform(0,1) [on hold]

Given Random sample {X_i} from Uniform (0,1) for i=1,2,3,4. Let \tau denotes the median. Find the PDF of \tau i.e. PDF of the Median.
0
votes
0answers
7 views

Combing variables in STATA [on hold]

I've got 8 binary variables (0,1) and I want to create one categorical variable for each. I've tried gen varNew = 1 if (var1 == 1), 2 if (var2 == 1) But it doesn't work. Hopefully you see what I ...
0
votes
0answers
7 views

R package topicmodels, how are probabilities calculated in case of trained model with new text [on hold]

When scoring new text documents with a trained topic model (LDA() function in r package topic model) the posterior() function ...
0
votes
1answer
19 views

Is margins simply a probability? (STATA)

I've run a logistic regression on two binary 0,1 variables. One is "seizure yes, no" the other is "sex, male, female". Now if I run a margins command on these variables, I get a number as a result. I ...
1
vote
1answer
26 views

RM anova or Factorial Anova?

I have an intervention in a group of schools. I think I need to use RM anova since RM Anova is 1 factor between subjects and other one within subjects (time) while factorial anova is two factors ...
0
votes
0answers
12 views

Bonferroni for Wilcoxon signed rank?

I conducted a survey that asked participants to rate their level of agreement on a 5 point Likert scale with nine items (1=strongly agree, 5=strongly disagree). Hence, a mean score of 3 would mean ...
1
vote
1answer
29 views

How can I make a Kolmogorov-Smirnov test to check if my data distribution is exponential?

I made a histogram of my data, and the fitting line, but from some reason the fitting line doesn't fit to my graph. How can I make it fit to it? How can I check if my data distribution is exponential?...
0
votes
0answers
21 views

Logistic regression with ordinal independent variable

I want to see whether patients have a higher risk of seizures, the bigger their brain tumor. My dependent variable is therefore "seizure (yes, no)" and my independent variable is "tumor size" ranging ...
0
votes
0answers
10 views

How to test the validity of Fitt's law in R

I would like to use the Fitt's Law to test some hypothesis. Anyway, it's the first time I use it, and I have some doubts. Then aim of my experiment is to test if in a certain situation the Fitt's law ...
0
votes
0answers
12 views

Unbiased Estimator of the Error Third and Fourth Central Moment in Regression Analysis

In linear regression an unbiased estimator of the error ($\epsilon$) variance is given by: $$MS = \dfrac{1}{n-p-1}\sum_{i=1}^{n}\left(y_{i}-\hat{y}_{i}\right)^{2}$$ which is the sum of squares of ...
0
votes
2answers
14 views

Regression for individuals grouped using fixed effect

I have some questions about how to define my regression. So, I want to use fixed effect model in order to estimate the effect of trade openness on gini coefficient. I include 58 countries including ...
0
votes
0answers
10 views

How to calculate log-rank test statistic

Depending on which statistics text you read you will get 2 different formulations of the log-rank test statistic. In some texts you will see it specified as: $$ \frac{(O-E)^2}{E} $$ Example 1 Whilst ...
1
vote
0answers
39 views

Wrong fitted parameters in multivariate linear regression?

I am implementing multivariate linear regression using numpy, pandas and matplotlib. I then ...
0
votes
0answers
12 views

TBATS, daily data, and room nights forecasting [on hold]

I hope this message finds you well. After some research I came across the application of TBATS model for the forecasting of room nights in the hospitality sector. Is there any detailed R guide that ...
0
votes
0answers
15 views

How to simulate average data based on time series model? [on hold]

I am using R Studio. I have a dataset of electric load for a building taken at 5 minute intervals for an entire year. I generated a time series vector using a daily frequency and have trained an ARIMA ...
0
votes
0answers
13 views

Please help me to find the sample size?

I conducte a survey in a state related to perception regarding child sex ratio, for this I selecte the two district with high and low child sex ratio,now I travel with that how I selecte the sample ...
0
votes
0answers
14 views

Multicollinearity between categorical and continuous predictors [duplicate]

How can I check collinearity between categorical and continuous predictors (there are four predictors)?
0
votes
1answer
22 views

sampling from normal distribution using MCMC doesn't seem correct [on hold]

I'm trying to sample from the normal distribution with a mean of .5 (like flipping a coin) and an arbitrary standard deviation using a markov chain (sequence of numbers where each number is dependent ...
-1
votes
1answer
39 views

UMVUE of $\cos\theta$ when $X_i\sim U(0,\theta)$

$X\sim U(0,\theta)$. To find the umvue of $\cos\theta$ is it enough to find the umvue of theta and substitute for it. Umvue of $\theta$ being $(n+1)X_{(n)}/n$, is the answer $\cos (n+1)X_{(n)}/n$?
1
vote
0answers
12 views

Do all parameters have to have the same nature in a structural change test?

This is a duplicate of this query (I was asked to shift the query from economics.stackexchange to Cross Validated SE.) Lets say I am building a market model to estimate the beta of a stock with ...
1
vote
1answer
11 views

Intuition / motivation for 2 “measure” values on a bullet chart

I am trying to understand a bit more about the statistical intuition behind bullet charts. This one in particular has two "measure" readouts, one is dark blue one is light blue: For clarity, the gray ...
0
votes
0answers
14 views

How to properly use BLEU score to compare your model to existing models?

So I am using the BLEU score metric to evaluate and compare my neural machine translation model's performance with existing models. However, I'm wondering how many criteria do I have to match with the ...
0
votes
0answers
12 views

Estimating common slope across two traits for a parallel growth curve model

I am using a parallel growth curve model with 5 waves longitudinal data to evaluate correlated change among 2 traits. For models that showed the effects of correlated change among traits, I'm ...
1
vote
1answer
20 views

Using predict() on a multiple regression object with specific values set for some of the predictors

final.reg1<-lm(formula=medv~.,data=Bostondat) Here's the Multiple regression model I'm running on the Boston data set. I would like to predict the medv for the case when crim=0.05,rm=8,tax=279,...
0
votes
1answer
10 views

Can I create a composite variable for my two dependent variables?

I am working with two dependent variables that are both measuring a country's level of nuclear security. The first variable is a country's nuclear security index rating (range 1-100). The second ...
0
votes
0answers
29 views

scale with z-transform with the outliers in the data

I have 2 different columns X1, and X2. As you can see scale of X1 is larger than X2. These 2 columns represent the predicted value of performance of my two products. However the range or scale of X1 ...
0
votes
1answer
13 views

How to calculate correlation for 2 time series where the tick times do not line up

I'm looking to compute intraday correlation for 2 tick by tick intraday commodity price time series. The tick times do not line up across the 2 time series. I'm thinking of converting the time ...

15 30 50 per page