instruction
stringlengths
9
38.7k
I'm very new to both Gibbs sampling and LDA. Currently, I'm trying to understand the collapsed Gibbs sampling method in LDA. However, I'm quit confused about the whole method when reviewing the algorithm. Here are my confusions and I badly need some guidance. For short, let $W$ be the set of all the words in the corpus...
Can anybody tell me what type of data this is, I am not sure what type of categorical data it is as I need to perform the correct statistical test: Birth weight of newborn babies: low (<2500g) or high (>2500g) As there are only two categories I am not sure what type it is (ordinal, nominal or binary). Thank you!
How do you compare sex ratio in R? I have surveyed a population of species and found 12 males and 1 female. I wish to compare the sex ratio in my sample to the expected 2:1 sex ratio of this species and then present the results of my analysis of this data. Then display my conclusions. I have had few lessons in R but am...
I have a question regarding the problem outlined in the picture. Two bars of different lengths x_1 and x_2 can be located anywhere within their associated intervals (B_1 - B_2) and (A_1 - A_2) (uniform probability). What is the probability that they overlap? I tried to solve this problem similar to the problem of two p...
I have a dataset of about 1000 features and 2000 training examples. I use Randomized Search with cross validation to compare Random Forest, Linear SVC, SVC with different non-linear kernels, and Logistic Regression. I consistently get much worse scores with Linear SVC than with the other models, including Logistic regr...
In logistic regression, when one omits a relevant regressor, the estimates of the coefficients of the other regressors are affected in that they're shrunk, see Mood 2010 This phenomenon is easily interpreted when looking at logistic regression as a latent factor model where one estimates the logit + logistic distributi...
I am working on an anomaly detection problem and have come across a paper(https://www.ijcai.org/proceedings/2019/0378.pdf), which shows results where in the ROC AUC value for a dataset is 0.566 and the PR AUC for the same dataset is 0.908. Can someone please explain to me in what case/scenarios this is possible?
When fitting an ARIMA model using the statsmodels python implementation I see the following behaviour, python does not seem to correctly provide the values for the differenced lags. I am comparing the results with the ones obtained using the R ARIMA implementation. Scenario: Seasonal non-stationary data which requires...
I'm currently trying to implement the method from a paper (DOI: 10.3389/fnins.2015.00308). In short, I have $K$ classes which are spread across $N$ segments of EEG data for each channel $c$. For each segment I have projection weights $w_i$ I gained by applying a PCA. To choose which EEG channels to be used for further ...
I am attempting to employ the synthetic control method (SCM) to analyze the causal impact of a UN peacekeeping operation (PKO) on post-conflict peace. I am operationalizing post-conflict peace as both the number of fatalities produced by terrorist violence and the count of terrorist attacks. In both cases, these outcom...
Consider a family $S$ of probability density functions on $X$ which is defined as $p:X\to\mathbb{R}$ such that $p(x\geq 0)$ and $\int_{X}p(x)dx=1$.Suppose each element of $S$ may be parameterized using real-valued variable $[\xi^1,\ldots,\xi^n]$ that is $S=\{p(x;\xi):\xi=[\xi^1,\ldots,\xi^n]\in E\subseteq \mathbb{R^n}\...
Here's my code : mammal.pca_no.corr <- prcomp(PCA_mammal_dataset_no.corr, scale = T) summary(mammal.pca) mammal_pca_no.corr$rotation And here's the output: Importance of components: PC1 PC2 PC3 PC4 PC5 PC6 PC7 PC8 PC9 PC10 Standard deviation 2.6653 1.4929...
I want to solve the following optimization problem: $$ L = n^{-1} \sum^n_{i=1} w_i ( y_i - \tau(x_i))^2 $$ where $w_i \in \mathbb{R}^+$ weights, $y_i \in \mathbb{R}$ outcome data, $x_i$ features/covariates, and $\tau$ an unknown function to be specified or approximated by a machine learning (ML) algorithm. For exampl...
I am currently writing my bachelor thesis ans I've recently gotten into ML and logistic regression and I'm a little confused as to the assumption that the observations are independent. I found this post: https://towardsdatascience.com/assumptions-of-logistic-regression-clearly-explained-44d85a22b290. It describes how t...
In competing risk settings, the Cox model gives correct HR's if we censor at other event types (i.e. the Cause Specific Model): https://statisticalhorizons.com/for-causal-analysis-of-competing-risks/ Is it valid to use this censoring approach in a sampled nested case control dataset, on which we subsequently fit a cond...
I am working with a large dataset and applying multichannel sequence analysis to two life course domains. I would like to adapt a solution suggested in the post below to multichannel sequences, but I cannot find a way to adapt TraMineR seqdist() so that it works with multichannel sequences. I am looking for a way to ca...
My question here is related to the following question I posted here: Joint posterior distribution of differences With respect to that last question, what I want to discuss is how to appropriately sample from the posterior predictive distribution of the differences, i.e., the distribution $p(x^*-y^*, x^*-z^*,y^*-z^*|x,y...
I think I know in general how to derive the maximum likelihood estimation for a parameter given a distribution. But I can't wrap my head around this one! We have the observations: $(y_1, x_1),...,(y_n, x_n)$ from a random sample where: $Y_i \sim N(\beta x_i, 1)$ for $i = 1,2,...,n$. We are interested in the expected va...
A coin was flipped 10 times and landed on head 9 times. We want to test $$H_0: p = \frac{1}{2} \ vs \ H_1: p > \frac{1}{2}, p = \mathbb{P}(head)$$ with a confidence level of $\alpha = 0.05$. The question specifically ask for: The test statistic Distribution under $H_0$ The conclusion of the test and the $p$-value. My...
I've constructed a GAMM on some environmental variables (water temp., salinity, etc..) to see if there are significant differences between the months in which we collect data. Values obviously change by month and year (time of day and location too), but I'd still like to test each month in a pairwise comparison later (...
I'm running an A/B test to determine if a change/treatment we're proposing for our website has an impact on users opting into a specific (niche) category of notifications. To do so, I'm performing a one-tailed z test of two independent proportions (treatment vs control). However, I'm concerned with the results of my te...
If there are four variables each with five observations: X1 X2 X3 X4 5 3 0 2 0 9 -9 0 3 1 0 2 7 3 0 4 5 2 0 3 Why can't you regress a dependent variable Y on X1, X2, X3, and X4? I have a feeling it is because of collinearity and it violates full rank assumption, but could someone explain why in grea...
Here: What do the residuals in a logistic regression mean? is a description of the different ways how one can generate residuals from a logistic regression. My question concerns not the logistic regression specifically, but any regression with a binary outcome, apart from OLS and the generalized linear model for binary...
My data contains three parameters, i.e., Treatment, Time, and Temperatures. I am looking into the effects of these three parameters and their interactions as I measure neuronal activity. The activity measures are neuronal phase (a relative timing of neuron's activity in a cycle period) and cycle frequency. So far, I ha...
I've recently conducted an experiment where 24 participants performed a set of four tasks twice - using two different virtual reality interaction methods. The tasks consisted of a game similar to whac-a-mole, repeating hand gestures, pointing at targets and building a tower. Completing each task resulted in a score bas...
I'm using lmer to look at the interaction between continuous variable baseline and grouping factor condition (8 levels) on continuous variable outcome post. There's a significant interaction between baseline and condition. Some of the slopes, e.g., ConditionR concha 25:Baseline, are significantly different from the ref...
Consider I have a linear model fitted in R as: model<-lm(y~x*fac) where x is a continuous variable and fac a sum contrast coded two level factor (-1,1). now I can check the coefficients of my model and do t-tests to check if: the main effect /slope of x (averaged over the two factor levels) is significantly different...
For simplicity, let's assume that we have the true DGP $$y_i= \beta_0 + \beta_1x_i + \epsilon_i$$ where $\epsilon_i \sim N(0, \sigma^2)$ $(i = 1,2,...,n)$ Assume that these following usual assumptions meet (for the classical linear regression model) $y_i= \beta_0 + \beta_1x_i + \epsilon_i$ (linearity) $x_i$ is determi...
According to pg 2 of the pdf http://www-stat.wharton.upenn.edu/~rosenbap/BehStatSen.pdf, "however, this alternative method takes account of sampling variability and is applicable to any kind of response; see, for instance, [25, 26, 29], and Section 4 of [28] for detailed discussion. Alternative methods of sensitivity a...
I am trying to compare two models: Costs = Income + Education1 + ... + Education10 and Costs = Income From the ANOVA table using anova() in conjunction with the corresponding lm() objects, I get that the p-value is < 2.2e-16. However, I was wondering if there was any way that the numerous factor levels in Education cou...
The Wikipedia page states this in the decompositions section, and it is also stated in an older paper I have never been able to understand these explanations, and I wonder what I am missing and if there is an easy way to understand this... How does one get from this... $$ BS = \frac{1}{N}\sum\limits _{t=1}^{N}\sum\limi...
I am aiming to compare predictions made using 10 different models with no reference to the observed value. The objective is two folds : i- check if the difference between the models predictions are significative ii- and which are the models that are similar to each other in terms of predictions. For that purpose, I tho...
Consider I have a linear mixed effect model fitted via the R package lme4 with a nested random effect structure as: model<-lmer(y~x+(1|A/B/C)) If I look at the variances of A, A:B, A:B:C do they tell me how much variance is left in say C when controlling already for the random intercepts in A and B? If I do not care a...
I have frequently read about long term and short term forecasting in time series analysis, but I didn't get how this is determined. Is this empirical values and why? How can I determine the horizon in different term forecasting (like based on percentage of input data)? I would appreciate references.
If a regression has 100 observations and 100 variables and none of them are collinear, what is the r squared? I know that it means that the full rank assumption is satisfied, so does this mean the r squared equals 1? Also, what would the t-statistic for the 5th coefficient be?
In this question, the OP runs a “chunk test” and has a linear relationship between a variable in the restricted model and the variables in the chunk. If this were a chunk of just one variable, that linear relationship would manifest through the variance-inflation factor and inflate the p-value of the t-test of that one...
I am trying to find the keyword (if there is any) for the technique in which we use the same deep learning architecture that works well in one domain and train it again in another domain to find out that the architecture (not the trained model) is suitable for both the domains. It is unlike the word "domain adaptation"...
Let $N\sim \hbox{Poisson}(\lambda)$ and $(X_t)_{t \in \mathbb Z}$ be a stochastic process. Consider the following stochastic process: $$ Y_t = \sum_{j=1}^N X_{t,j}$$ where $(X_{t,1})_{t\in \mathbb Z}, (X_{t,2})_{t\in \mathbb Z},..., (X_{t,j})_{t\in \mathbb Z},... \overset {\mathrm{i.i.d}} \sim (X_{t})_{t\in \mathbb Z...
We always use latent variable approach to derive probit model, is there any way to derive probit model from the exponential family form (by using link function)? Also, does logit-normal distribution has relationship with probit model? Thank you!
I am trying to calculate the variance: $$ \langle(\bar{O}-<O>)^2\rangle $$ of the Monte-Carlo estimator $$ \bar{O}=\frac{1}{M}\sum_{m=1}^M{O_m} $$ For uncorrelated samples. In order to do so, I need to know the expression for the covariance between two samples (so I can use: $Cov(O_m,O_n)=0$) but looking at definitions...
The formula of autoregressive model is y(t) = beta_0 + beta_1 * y(t-1) + Error To me it seems the same as linear regression. I used lm function in r it gives this result: I also tried package in python. I used stats models.tsa.ar_model The result is: I checked the residual plot and of the lm model and it seems to be ...
I have a MARS model, say: set.seed(1111) test <- tibble( x1 = runif(rnorm(5000, 5, 10)) * .33, x2 = runif(rnorm(5000, 5, 10)) * .44, x3 = runif(rnorm(5000, 5, 10)) * .55, x4 = runif(rnorm(5000, 5, 10)) * .66, y = runif(rnorm(5000, 10, 2)) * 10 ) test_fit <- earth(y ~ ., data = test) test_fit |> coef() ...
I am working on the movement of fish species from the centre of a protected area to a non-protected area. Based on the article by R. Abesamis, itself inspired by the work of B. Kaunda-Arar (page 91), I applied to my dataset a logistic decay D = 1/(1+exp(S*(I-d)) where D is the proportion of biomass in the middle of the...
I have a question regarding Omitted Variable Bias (OVB): I know that endogenous predictor can be an issue, as the association between the dep. variable and the indep. variable could be confounded by another variable, which is not controlled for in the model. I'm wondering though whether the exogeneity of a predictor is...
I'm running a PERMANOVA analysis using vegan's adonis2. I have (rarefied) fungal community data (18S sequencing) of 24 samples. As treatments I have subplot (1,2,3,4,5 or 6) and state (con and sup). Each subplot has 4 samples and a subplot is seen as either 'con' or 'sup'. Thus metadata looking like: To perform the PE...
I work with Nanopore DNA sequencing and do a taxonomic classification of each read - that is to infer which species it originated from. However, this process is not perfect because of the available databases, and so I want to filter the results afterwards. For the true positive identifications I expect the DNA reads to...
Group A includes 20 students who took an exam and their grade mean was 28(±9.15). After taking the second exam, their mean grade has decreased by 14(±9.9) in comparison with the first exam. My question is: How to find the average score of their second exam if it not given? I know that I can subtract the averages and ge...
I wasn't able to find anything on google, but is there a variant of the Metroplis-Hastings algorithm where the acceptance probability (not the proposal kernel) in the $i$th iteration might depend on the stats $X_0,\ldots,X_{i-1}$ generated so far? I guess the problem is that the resulting process is not a time-homogene...
A common way of getting confidence intervals for the mean of a normal random variable is to estimate the mean and variance by the method of moments and then compute a confidence interval based on those estimates. Since this is commonly used, I would assume that these are asymptotically valid and (in some sense) optimal...
I have a categorical variable that encodes the answers of a certain population to particular question. Each respondent can give multiple answers. Which statistical test do I need to perform to check if the difference in the number (or perhaps better percentage) of people that gave a particular answer is statistically s...
Suppose I have two random variables, $X$ with PDF $f_X$, and $Y$. Moreover, I know that $Y = h(X)$, and I do know the $h(x)$. Now I want to calculate the conditional expectation of $Y$ given $X$: $$ E[Y|X] = E[h(X)|X = x] = E[h(X)] = \int_{-\infty}^{\infty} h(x) f_X(x)dx $$ Is that correct, that despite not knowing the...
A hypothetical pharmaceutical company organizes a poorly designed study as follows : It simply gives out its experimental drug to a pool of people with traits $X$. Only some of them are actually sick and the chance of them being sick depends on $X$. They only take the drug if they are sick, but doesn't necessarily do s...
I was just reading a paper in the field of education and there was a part I couldn't comprehend. The author did a multilevel regression analysis with the data which was nested in a school level. So that the 2nd level was school. The dependent variable was school violence. The syntax in R would be like lmer(violence ~ (...
The refutation methods in the dowhy causal inference library are useful. https://www.pywhy.org/dowhy/v0.8/dowhy.causal_refuters.html I'd like to learn a theory that explains these methods well, but I'm not sure what to search for to find resources that explain them. What materials should I look at for knowing them? Wha...
Disclaimer: I'm new to the potential outcome framework so this question may not make lot of sense, in case please let me understand where I am failing. I was reading this question about the unconfoundedness assumption for Rubin's causal models that claims that the potential outcomes are independent of the treament give...
My posterior distribution $$ p(\theta\mid y) \propto p(y \mid \theta) p(\theta) $$ has a prior $p(\theta)$ that is a $\text{Beta}(2, 2)$ rescaled between $(0, 10)$. I don't want my parameter to be constrained, so I want to write it in terms of an unconstrained parameter $\vartheta$, preferably with prior $p(\vartheta)=...
Let’s say I have fitted a regression model on a large dataset, and I obtain an estimation performance metrics (R-squared, RMSE) for the whole dataset, via cross validation or via a test set. However, this estimation is relative to the whole dataset, with no difference in different parts of the feature space. It would b...
The discrimination of an item can be calculated as: $$D = \frac {K_h-K_l}{N}$$ Where $K_h$ is the number of correct responses from the high scoring group, $K_l$ from the lowest scoring group (top and bottom 27% usually) and $N$ the number of individuals in either group. This is a measure of the item's ability to discri...
Would it be unwise to scale the Sex variable? I'm teaching myself Clustering and will probably attempt UMAP, T-SNE, and K-means soon. I saw someone else scale this dataset in Python. All the other variables, I understand. The first though, I don't, since there is only 0/1, Male/Female. Thoughts? Also, how would you go...
I am conducting a multi-variate time series forecasting using an LSTM model. The model architecture and other details are given below: Dataset split: (80/10/10 split) Training Data Points: 367640 Validation Data Points: 45388 Test Data Points: 40849 Features Scaling: (After data splitting) MinMax Scaler(-1,1) Model Arc...
I'm trying to derive conclusions on how uniform distributions with different alphabet lengths influence the information measured from any other random variable (not neccesarily uniformly distributed). Overall we measure the reduction in the uncertainty of the RV $X$ given $Y$ is observed by means of: $$H(X|Y) = H(X,Y)-...
I am working with a food preference dataset where individuals rank their food preferences (apple, banana, orange, coconut, pear). The goal is to determine whether one fruit is ranked as 'favorite' more than another. There are a few interesting aspects to the data: People do not rank fruits they have not tried, so som...
I know that the synthetic control method is used to estimate a causal effect by finding the difference in outcome between a real treated unit and a synthetic non-treated unit. However, I was wondering if it is possible and mathematically sound to use the synthetic control method to estimate the opposite counter-factual...
I am dealing with a problem that contains multiple categorical features and different time series depending on these variables. So, for example the dataset can be represented as: Day catA catB catC productA 1 A B B 1.8 2 A B B 2.4 3 A B B 2.8 4 A B B 3.8 5 A B B 4.4 6 A B B 4.8 7 A B B 5.4 ... ....
I'm doing the t.test from a paired sample, only considering as alternative hypothesis that the mean is greater than 0. Why the confidence interval has a minimum value but not a maximum? The only reason I can think of it is that the maximum value of the mean is not as important as the minimum value if your restriction i...
I have a following problem: Consider observations $Y_i, X_{i,1}, . . . , X_{i,p}, i = 1, . . . , n$ modeled as $Y_i = β_0 + β_1X_{i,1} + · · · + β_1X_{i,p} + ε_i$, where $ε_i$ are assumed to be i.i.d. random variables with Gaussian distribution $N~(0, σ^2)$ and $β_0, . . . , β_p ∈ R$ and $σ^2 > 0$ are unknown model par...
I ran a binary-logistic regression in SPSS. Block 1 shows that the Omnibus Tests of Model Coefficients is insignificant for step, block and model, p =1.06. However, I have two significant predictors in the Variables in the Equation Table. Because the Omnibus test is insignificant, are my two predictors also insignifica...
Consider the Metropolis-Hastings algorithm with proposal density $q(x,y)$ and target density $p(y)$ with respect to some reference measure $\lambda$. If we don't use the proposals $Y\sim q(x,\;\cdot\;)\lambda$ directly, but replace them with $\lfloor Y\rfloor$, is there such a variant of the Metropolis-Hastings algorit...
Hopefully, this post is appropriate for CV and won't be closed. I have a non-symmetric matrix $M_{K \times K}$ comparing a new statistic, $\delta$, my colleagues and I developed and tested on a variety of $K$ species. $\delta$ ranges between 0 and 1, inclusive. I've computed $\delta$ for all species pairs. Thus if the...
The distribution function of a random variable $X$ is defined by $F(t)=P(X\leq t)$. If I have another random variable $Y$, then $F(Y)$ is also a random variable. But, using the definition, we have $F(Y)=P(X\leq Y)$, which is a number. A simple example I invented myself: $X\sim\text{Exp}(1)$, $F(t) = 1 - e^{-t}$, $Y\sim...
I want to predict whether a machine will fail based on the most recent set of measurements taken by on-board sensors. I have several dozen machines, each with a sensor that takes a measurement at regular intervals. Some machines have already failed, but most have not. The resulting dataset looks something like the exam...
Are there any named metric that calculates TP/(TP+FN+FP)? It is like the accuracy, but disregarding TN In my problem, we have thousand of possible labels. However, the models return a small list of labels(usually 1 to 5). The true values are also a small list. Weighting for FN and FP is important because I dont want th...
Suppose I have the following problem - we are interested in modelling the number of animals that cross a certain point each year (e.g. swim across a river). Let's say that these animals typically migrate during the summer months (e.g. April - September), and in the winter months this number becomes almost becomes 0. Su...
Suppose I have two sets of three numbers: $x_1, x_2, x_3$ and $y_1, y_2, y_3$ and I want to test the Null hypothesis that they are drawn from the same distribution using the Wilcoxon-Mann-Whitney test. So what I would do with pen and paper is the following: Compute the test statistic $W_{observed}$ for my sample Make ...
I wanted to get random values for a logarithmic distribution but I only have max and min values (and not the mean and sd). Is there a way to do this in R?
Let's say you have an artificial neural network (ANN) where the last layer is a softmax, so the output could be interpreted to be a categorical distribution, i.e. output neuron $i \in \{0, 1, \ldots, N-1 \}$ represents the probability the ANN "thinks" the input sample belongs to class $i$. Let's say that that we restri...
After writing a simulation in python (code at bottom) I realized my calculations are incorrect but can't figure out where I went wrong. Let {$D_1$, $D_2$, $D_3$, $D_4$} be the ordered dice rolls. Let $X = D_2 + D_3 + D_4$. $$E[X] = E[D_2 + D_3 + D_4] = E[D_2] + E[D_3] + E[D_4]$$ I treated each $D_i$ as an order statist...
When it comes to Survival Analysis, I understand that there are 3 main classes of models: Non-Parametric Models Parametric Models Semi-Parametric Models Non-Parametric models are like the Kaplan-Meier model - they do not require the outcome variable (i.e. survival times) to have a particular distribution. This makes ...
A few times people have auggested to me to run a log reg with survival time as a covariate in place of a cox proportional hazards analysis. I am sure this has drawbacks but I am not sure what they might be. Anyone have an idea? When would you use one instead of the other?
In a hypothesis test, the null hypothesis $H_0$ is rejected in favor of $H_1$ if $|\bar X|>\mu$. When tests found that $\bar x$ is the mean of the samples, a p-value is computed using $$ p=\Pr(|\bar X|>\bar x) $$ Using (e.g $\bar X\sim t(n-1) $ the p-value is obtained and the conclusion is: Tests with significance lev...
I'm struggling to find some clear math behind ensemble learning. I can simulate it very easily, eg: import numpy as np, scipy.stats r = np.random.random(1000) d = np.array([0]*1000) cors = [] for i in range(100): v = np.random.random(1000) c = scipy.stats.pearsonr(v,r).statistic cors.append(c) d = d + v * c # <...
I'm using the felm function in R for time-fixed effects but I'm having trouble specifying my model. I tried the following two but they result into completely different outputs. Could you explain what does the 0 stand for? Which of the following models would be correct for my analysis? My sample consists of 400 observat...
I have a little over 27,000 Facebook posts stored in a database. For each post, if the post has comments and replies, those are also stored in the database. The posts are from Facebook autism groups. I am dividing the posts into what I call the scam era and the pre-scam era. The pre-scam era is the time period before 1...
I try to compare the forecasting performance of several models. I do it for two situations: normal and extreme cases. My dataset set is not big. One of the models (gradient boosting) requiers a minimal training set which is bigger than the other models (45), which makes the extreme cases check a bit useless. In each it...
My hypothesis is that age predicts how resilient you are. So I need to run simple regression analysis on SPSS. Age is measured in years and resilience is measured on a scale where you can achieve a total score between 1 and 94 (the higher the score the more resilient you are). As I therefore have two different scales m...
Suppose we have the following PDF of X: $f(x)=\frac{1}{4}(2-x)\;;-1\leq x\leq 1$ We want to use $g(x)\sim\mathrm{Unif}(-1,1)$ as a proposal density to generate samples from $f(x)$ using a rejection sampling. Our usual approach will be, to find $M$ such that $M=Sup_{x\in [-1,1]}\frac{f(x)}{g(x)}$ But we can not calculat...
Both Akaike's information criterion and Bayesian information criterion are calculated from the loglikelihood, eg AIC= -2 log-likelihood +2k. To the likelihood of what does it refer to? The likelihood of 1) the model that I fit to the data or of 2) the distribution I draw my data from at each point? So, with 2) I mean, ...
I want to perform a competing risks regression analysis. There are 3 competing risks + censored data. I would like to know if there is a way to calculate the minimal observations I will need per event to have enough statistical power. For example, I have 40 observations of patients that finish the treatment without any...
If an n-dimensional model $S=\{p_{\theta}| \theta\in\Theta\}$ can be expressed in terms of the functions $\{C,F_1,\ldots,F_n\}$ on a sample space $X$ and a function $\psi\in \Theta$(parameter space) as $$p(x;\theta)=\exp\left[C(x)+\sum_{i=1}^{n}\theta^{i}F_{i}(x)-\psi(\theta)\right]$$ then we say that $S$ is an exponen...
I am running into a tricky issue with the execution of the synthetic control method for my data. For reference, my outcome data has an odd temporal gap (uniformly, across all units, no data is avaliable for 1993). However, temporal coverage is sufficient barring this one-year gap. Unfortunatley, across various units, t...
I have received this confusing task: You have two variables and , where y is a response variable which can be written as an explicit linear function of . However, the technique used for measuring is twice as better than that for measuring in the sense of error variance, i.e. the variance of the error in is twice as...
One of the functions that helps to characterize clusters is the catdesc() function. The output of this function is very informative giving the following bits of information: Cla/Mod, Mod/Cla, Glabal, p-value, and v-test. In this post, I want to know what is going on under the hood regarding the calculation of v-test an...
I am currently working on a machine learning model that yields a vector of offloading decisions. An example: [-1, 0, -1, 1, 1, 0, ...] The model does not return this vector directly. Instead, the model has 3 output layers, each returning the softmax result for a particular decision. e.g.: each of the below ones has the...
How do I find the value at risk at 90% confidence interval i.e., VaR(10%) for a portfolio with the following profit/loss distribution? [-120 with prob = 0.0036, -55 with prob = 0.1128, and 10 with prob = 0.8836] I know the formula VaR(10%) = -(µ - z(0.9)*σ) but get the wrong answer when using it. Any help would be much...
I want to study the correlation between the individual's level of education (1=high school or less, 2=associate degree) and the customer service received in a convenience store (1=good, 2=bad), should I use spearman or phi test?
I have conducted an experiment looking at the decay rate of a DNA target in flowing water over time, with 4 replicates of each treatment. The data is collected via dPCR Quiacuity instrument that calculates well concentrations (gene copies/uL) based off of positive and negative plate partitions. At some time points (see...
My question is what kinds of events is multivariate Poisson distributed ? I need to find or generate a dataset which has got this distribution ? I thought of random vector $X=(X_1 , X_2)$ where $X_1$ descirbes the goal per game and $X2$ describes the foul per game for a football player ? But I am not sure if my $X$ th...
I have been told that one of the main advantages of Semi-Parametric Models (e.g. Survival Analysis, Cox Proportional Hazards Model) is that these models do not require assuming the response variable (e.g. Survival Times) to follow a specific probability distribution, thus allowing for a higher level of flexibility. Thi...
I am currently studying the textbook In All Likelihood by Yudi Pawitan. In chapter 2 Elements of likelihood inference, the author presents the following example: Example 2.4: Suppose $x$ is a sample form $N(\theta, 1)$; the likelihood of $\theta$ is $$L(\theta) = \phi(x - \theta) \equiv \dfrac{1}{\sqrt{2 \pi}} e^{-\fr...
I am trying to simulate a dataset based on an existing study. 60 participants completed the experiment twice. Each time, they were randomly assigned to either condition A or condition B. The condition assignment was independent of the measurement time, so the same participant might or might not have been assigned to th...