instruction stringlengths 9 38.7k |
|---|
I run a null binomial generalized additive models (gam) using mgcv and it gives negative deviance explained!
As far as I know deviance explained is analogue of R^2 so it should be between 0 and 1. So is this negative deviance explained occurred by the package error? If so, then how can I manually estimate deviance expl... |
Consider a simple regression model $Y_i = \alpha + \beta X_i + u_i, (i=1,...,n)$ where $(Y_i,X_i)$ is a random sample. Let $\hat{\beta}$ be the OLS estimator of $\beta$ and $\bar{X}$ be the sample mean of $X_i$ given by $\bar{X}=n^{-1} \sum_{i=1}^n X_i$.
I'm trying to derive $Var((\hat{\beta}-\beta)\bar{X})$. If $X_i$ ... |
Suppose I have a likelihood maximisation problem
$$ \hat{\theta} = \max L_n(\theta;y) $$
where $\theta = [\theta_1, \theta_2, ...., \theta_k]^T$.
What if I would estimate instead estimate the maximisation problem leaving out a parameter
$$ \hat{\theta_{-k}} = \max L_n(\theta_{-k};y) $$
but a loop over each value of $\t... |
I am developing a credit risk decisioning model, i.e. a model that assesses the risk of default of an incoming transactions and decides whether to accept it or not. Of course my dataset is imbalanced : the minority class (i.e. defaulted transactions) represents ~5% of my data.
What I care about is discrimination power ... |
I conducted a moderation analysis on repeated-measures data using the MEMORE macro for SPSS (https://www.akmontoya.com/spss-and-sas-macros). However, I need standardized effect sizes but I haven't managed to figure it out and it's quite urgent.
So each participant read 2 character descriptions about a healthy (Conditio... |
In the book Mathematical Methods for Physics and Engineering it is said that the likelihood function tends to a Gaussian (centred on the maximum-likelihood estimate) in the large sample limit. The way it is phrased makes it seem like they are saying this is due to the central limit theorem, but I am struggling to see h... |
I am looking for ways of estimating or mitigating the risk of applying a classification model (say logistic regression for simplicity) in a certain population (the inference set) that is known to be different from the training population. We know that our metrics estimated in the test set are not directly applicable to... |
I have an lme model with a significant categorical variable. I have recently been advised to test for autocorrelation in the residuals of that model separately for each level of that variable. The result is that some levels show autocorrelation and some don't and I am not able to deal with this autocorrelation by speci... |
So, I need to do some exploratory data analysis and I picked MDS to figure up if there were trends in the data.
The structure of my data looks like this:
$ Generation: int 2 2 2 2 2 2 2 2 2 2 ...
$ Panel : chr "A" "A" "A" "A" ...
$ Line : int 1 1 1 1 1 1 1 1 1 1 ...
$ Rep : int 2 2 2 2 2 2 2 2 6 ... |
I want to conduct a meta-analysis of single means. However, these means are restricted mean survival time (RMST) of cerebrospinal fluid shunt inserted to treat hydrocephalus.
For this, I have digitized published survival curves with https://apps.automeris.io/wpd/.
Then I have extracted the individual patient data with ... |
I'm working on Cox regression in my PhD research and I would like to know some references about applying the stratified-extended cox regression model on a real life data.
I'm interested about combining the two approach: stratification and the extended cox PH in a single model and not separately.
|
I have used RandomForestClassifier from Sklearn to solve a multiclass classification problem (12 classes in total). I get my x and y from a pandas dataframe.
label_bin = LabelBinarizer()
unique_classes = np.unique(y)
label_bin.fit_transform(unique_classes)
x_train, x_test, y_train, y_test = train_test_split(x, y, test_... |
I got contrary results from my log-rank (not significant) versus my cox regression (significant) regarding the effect of my treatment variable with the aim of hypothesis testing. That's no real wonder, considering that the cox regression adjusts for 6 covariates other than my treatment. However, I'm confused about th... |
I have a dataset containing a fair amount of continuous and categorical variables. I one-hot encode these variables to be used in various machine learning algorithms.
Let's presume a variable has n categories, which we one-hot encode into n columns. If we work with penalized models, we want to standardize all variables... |
Suppose $x$ is an isotropic random variable in $\mathbb{R}^d$ with $E[\|x\|^2]=d$ and $v$ is some vector. It appears that $\sum_i x_i^2 v_i \approx \sum_i v_i$ when $d \approx \infty$.
What is an easy way of showing it?
The hard way is to follow this answer or this paper.
|
I am currently running a mixed log-linear model which is in this form:
Log yit = Xit + X2it + (1|individu)
I suspect a multicollinearity ( cor (Xit , X2it) close to 1 ). Do you think it makes sense to scale the explanatory variables (Xit). Or is there another alternative? If yes, how may I interpret the result( 1 SD?).... |
Suppose I'm running a regression that looks something like
$log(price)=β_0+β_1log(X)+β_2log(X)^2$.
I have found the residuals, grouped them according to the number of sellers in the observation's town, and calculated the mean residual for each group. Suppose the residuals are 0.05 for 1 seller, -0.01 for 2 sellers, -0.... |
We know that for a sample (assume it's a data set that has two variables $x$ and $y$ of size $n$),
$$R = \frac1{n-1}\sum_{i=1}^n\left(\frac{x_i-\overline{x}}{s_x}\right)\left(\frac{y_i-\overline{y}}{s_y}\right)$$
Say we add in a data point $(\overline{x}, \overline{y})$ to the sample, which lies on the linear regressio... |
After logistic regression of the cross-sectional data sets, link test _hatsq shows insignificant. However, when I pool the same two data sets, the link test using the same set of variables regression gives significant _hatsq which shows specification error in the pooled data regression. Why is this happening?
|
Apologies if some of my terminology is incorrect, I only have relatively basic stats knowledge.
I have two groups of patients where we've done some experiments on the electrical conduction within the heart. Within each group, I've got a measurement of the degree of electricity abnormality (fractionation) during differe... |
Let $X_1,\ldots,X_n$ be i.i.d. log-normal random variables such that $$\log(X_i)\sim N(\mu,\sigma^2)\ \ \forall i=1,\ldots,n$$
Now let $Y$ be equal to the $\min(X_1,\ldots,X_n)$. It is quite easy to obtain the relation between the corresponding CDFs: $$P(Y<y)=F_Y(y)=1-[1-F_X(y)]^n$$
Is there a closed form to calculate ... |
i am confused at how to estimate the variance of a classifier. Currently, i have split my data into training and test sets and used the training data with a k-fold cross-validation strategy to get the best model.
Then, i could use the whole training set to train the selected model and then evaluate the test set, but i ... |
The calculation the MAD (Mean Absolute Deviation)/Mean ratio is this, according to the title:
$$
\frac{\overline{\left | Forecast - Demand \right |}}{\overline{Demand}}$$
However, the calculation is often shown as this, because of the derivation from wMAPE (weighted Mean Absolute Percentage Error), with sum not average... |
Generally, my default practice in regression for nominal categorical variables, including race, is to use dummy coding, with the majority/plurality level as reference. Interpretation of the model coefficients using this scheme is straightforward.
Additionally, I typically view comparisons to the majority/plurality grou... |
I have read that the Vuong test is no longer considered appropriate for testing whether a ZINB fits better than a negative binomial test because it is not strictly non-nested nor partially non-nested. I'm modeling in R (glmmTMB) and there is not the Vuong (nested) option that I can find. If the NB is nested in the ZINB... |
I have started reading this paper, and do not understand a line in its first paragraph in the introduction. He says:
Indeed, as far as the mean square error is concerned, Gaussian distributions represent already the worst case, so that in the framework of a minimax mean least square analysis, no need is felt to improv... |
Let $A_t$ and $B_t$ be $I(1)$ processes and assume that they are co-integrated i.e. there exists $\beta$ such that $A_t - \beta B_t$ is $I(0)$. Woolridge's Introductory Econometrics text (5th edition, page 646) claims that if we fix $A_t$'s coefficient at 1, then $\beta$ unique.
A naive proof would be to assume to the... |
I am using hierarchical GAMs to examine the effect of weather covariates (n=21) on annual bird counts. The hierarchical part is to account for nested observations with s(site, bs="re") and temporal autocorrelation with s(year, by=site, m=2). None of my covariates have significant smooths in the global model, so I have ... |
We have a Linear Hierarchical Model where
$$Y_i | \theta_i \sim N(\theta_i,1)$$
$$\theta_i | A \sim N(0,A)$$
with
$$Y_i |A \sim N(0,A+1)$$
where $ i = 1,2,\ldots,k.$
I found the likelihood function for $A$ by using the marginal distribution of the $Y_i$'s, where
$$L(A+1) = \prod_{i=1}^k f_{Y_i}(y_i | A+1)$$
$$ = [2\pi(... |
Suppose $X_1$ is a random variable. I want to test the hypothesis $$ H_0:X_1\sim \delta_0 \textrm{ vs } H_1:X_1\not \sim \delta_0.$$
Where $\delta_0$ is the Dirac-measure in $0$. As teststatistic I take T(x)=x, if i get the sample $x_1=0$, then I would calculate the p-value through
$$2\cdot\min\{P(T(x_1)\geq T(X_1)|H_0... |
I have a dataset with symptoms and its severity (integer: 0-10, over 20 variables), and a columns with chosen treatment (0/1, over 10 variables).
The dataset include over 1000 records.
Correlation plot seems inconvenient for me.
I am looking for a statistical test and/or visualization for analysis of associations betwe... |
Does anyone know where there is information on fit tests or something that can be done to help choose the best fitting family and link for a glm model? I have panel data that I am trying to run a regression with using a binary dependent variable (0/1). I am trying to decide between a glm with a poisson distribution and... |
I perform an LSA with textmodels_lsa of the quanteda package in R, but I have little idea about interpreting the results.
A minimal example taken from here
txt <- c(d1 = "Shipment of gold damaged in a fire",
d2 = "Delivery of silver arrived in a silver truck",
d3 = "Shipment of gold arrived in a truck... |
I am comparing the difference of medians between two groups of sample sizes $n1$ and $n2$. I would like to confirm that my boostrap approach for finite population size without pooling sample data correctly provides a distribution function of the differences between samples. Below, I provide examples of approaches that ... |
Steps followed for testing :
Derive parameter estimates using fitdistr() function in MASS package for the dataset, dt consisting of discrete values varying from 0 to 50.
df=dt[[1]]
nbfit <- fitdistr(df,'negative binomial')
pfit <- fitdist(df, "pois")
Use parameter estimates for creating reference distribution
... |
I'm writing my thesis on private equity funds' financial performance and ESG integration. The data is gathered from funds at a single point in time and is therefore cross-sectional data.
I want to run an OLS regression on the below dataset. I was a bit in doubt if I should use a logit model, however, as I understand it... |
I have the following model. Let $BP$ be a continuous variable s.t. true relationship is $BP=144+0.5age+4sex+3gene+\epsilon$. Suppose for subjects with $BP>160$, there is a probability of 0.5 getting some treatment with effect following truncated normal distribution with mean -15 and standard deviation $sd=2$, where tre... |
In GLM, we assume that $\mathbb{E}[Y|X]=\mu(\beta^\top X)$ and $Y|X$ follows exponential family distribution. I am going to assume that the probability of success in the Bernoulli distribution is modeled as $\beta^\top X$. However, the issue is that because $\beta^\top X$ can take values less than 0 or greater than 1, ... |
I have the following project in front of me:
Clients are going to get a bill informing them of a price increase (let's call them group A). However clients are getting the bill at different points of time.
I want to learn which individual characteristics eg age will make individuals to quit.
Then I want to use these lea... |
Really a pretty basic question about generative models, but I'm trying to map my (limited) understanding of NNs generally to what's going on when I invoke an OpenAI API:
When the OpenAI API docs state a limit to the prompt size for a model ("max tokens", which I assume is the same as what's also referred to as in the ... |
I estimated a variable for three different species and have a posterior distribution of 4000 estimates for each species. Now I want to know if the distribution between species differs significantly. How do I do this?
I have displayed the mean and 95% credible interval for each three species and would like to indicate i... |
Suppose we are using the matchit function from the MatchIt package in R, as in the following example given in the package,
m.out1 <- matchit(treat ~ age + educ + race + nodegree + married + re74 + re75, data = lalonde, distance = "glm", method = "nearest", replace=FALSE, caliper = NULL, ratio = 1)
Suppose now, you want... |
My model estimates the percentage of living-in agricultural workers (that is, the ones provided with board & accommodation) in labor force. The unit is the % of those workers in a district:
Y = a0 + a1 * cattle + a2 * horses + a3 * popden + a4 * altitude + e
Cattle and horses (more specifically, their densities, i.e. t... |
I want to run an A/B test to examine the effect of a marketing campaign on revenue. I’m using a synthetic control setup, hence I have to compare the revenue generated by treated units to the counterfactual revenue given by the synthetic control.
One way of assessing if there is a non-random effect of the campaign is to... |
I am modelling change in the mass of an animal over time with a GAM. These animals are caught at one of two ages (1 or 2, but 1's never become 2's in the subsequent year). I also have a large number of sites in my analysis.
The most simple model I am considering is:
mm <- gamm(MASS ~ s(YEAR.s, SITE, bs = "fs", by = A... |
The Forecasting Model
I have developed a proprietary forecasting model (call it AMA) that forecasts an expected range in price movement of a particular security. An example of the way it works is by giving out expected price range movement of $\mathrm{$10}$ for a $\mathrm{$100}$ stock within the next hour (or any given... |
I'm working on a machine learning classification project and i faced some difficulties: all of my features distributed like this:
I'm not sure what should i do, should i use any scalers/other preprocessing methods? All features means count of some events for a specific person. What problems can this distribution cause... |
I have a set of $k$ random variables,
$y_i(x) = f_i(x) + \epsilon_i, y \in \mathbb{R}$
where,
$\epsilon_i \sim \mathcal{N}(0, \sigma_n^2)$ (a noise term)
$x \sim \mathcal{U}(-\infty,\infty; -\infty,\infty)$ (a 2D uniform variable)
$f_i(x) = \varphi(x,\mu_i,\Sigma_s), \mu_i \in \mathbb{R}^2, \Sigma_s = \begin{bmatrix}\s... |
This is probably a very crude question and I've been thinking about it for a while. Is the odds ratio the same for generalized additive models (GAMs) as it is with generalized linear models (GLMs)? If no, then how can I interpret them in a logistic GAM? I found many links about odds ratios for GAMMs but not GAMs.
|
People sometimes include the interactions between their instruments and region/year or the interactions between different instruments in the first stage of a 2SLS regression. I wonder if the effect hierarchy principle applies to the instruments in 2SLS.
I'm asking this question because this paper selects instruments us... |
A colleague wants to analyze two outcomes (X1, X2). They believe the two outcomes measure the same construct or something similar. They decide to Z-score both outcomes in separate dataset and combine them (X3). They assume that because they are Z-scored they are now on the same scale, and because they are both measurin... |
Suppose I have three variables (x, y, z) and I am calculating their regression coefficients.
How to calculate Z-score between two variable (Z-score_xy) if Z-scores of two variable with a third variable are known (Z-score_xz, Z-score_yz)?
If you can show the calculation with beta would also be helpful.
Give reference pl... |
I am trying to develop a strategy to deal with outliers.
Below is the residual boxplot that I have generated for the test data, train data and both the test and train data.
My question is, what is the best way to deal with these outliers? Is it ok to just leave them if I had looked at them closely and there is no evide... |
Question
A drug maker wants to design a study in which two medications are compared. The first group has seen a improvement in 40%. Researchers want to see if the newer drug will improve this by 10% so they design a study. Assuming a study with power of 80% and a two-sided significance level of 5%. How many participant... |
I am considering the following log log model :
$$
log(y_t) = log(\beta_0) + \sum_{i=1}^{K}\beta_ilog(x_{i,t}) + \sum_{j=K+1}^{L}\beta_jx_{j,t} + log(\epsilon_t)
$$
to explain the sales of a company given several factors. After estimation of the model, I would like to "decompose" the dependent variable (the sales) by co... |
I'm trying to understand the proofs on the The information bottleneck method paper by Tishby, Pereira and Bialek without luck. In particular, the second term in the functional derivative of the Mutual Information, i.e.,
$$
\frac{\partial}{\partial p(\tilde{x} | x)} I(X, \tilde{X}) = \frac{\partial}{\partial p(\tilde{x... |
I have data with a large proportion of zeros that we are committed to analysing with ITS [to fit in with other parts of a project] and have been advised that the best approach would be to convert to a binary outcome. I've done so and fit a binomial glm to the data, but[with experience of more standard count/rate based ... |
I have run a binomial generalised linear mixed model (GLMM) via the lme4 package in R. The optimal model of mine is from this syntax: fm1 <- glmer (answer~ (1|subj) + (1|item) + seeconversationmask, data=analysis1, family=binomial, control=glmerControl(optimizer="bobyqa",optCtrl=list(maxfun=2e5)))
I have three independ... |
Can a Mann-Whitney test be done on different sample sizes, one sample about 18 and the other about 32? The problem is looking at the difference in views of tourists and locals about the environmental quality of a location.
|
I have a general population of let's say 100,000 people, 10,000 of which are on a register following a diagnosis of kidney disease (this involves looking at a blood result and coding a diagnosis). However, I hypothesize there may be more undiagnosed people in the 100,000 general population (blood results indicates but ... |
I am trying to identify a list of features that are significantly over represented in one population when compared to the other. Experiment is designed such that I have two groups of individuals A and B. Each group has 20 individuals. Over 2 million features have been analyzed in these two groups and for each feature i... |
Is it safe to run a logistic regression with time as independent variable? For example, I want to test whether a certain outcome (say, blue or red) changes along time. I know that, in general, one should be careful on time series because of autocorrelation.
EDIT: the dataset I have contains hundreds of observations pe... |
Why do some definitions of the Kullback-Leibler divergence include extra terms $-p_i + q_i$? For example, kl_div() (in the Python scipy.special module) defines the Kullback-Leibler divergence as
$$
\sum_i p_i \ln\frac{p_i}{q_i} - p_i + q_i.
$$
The documentation says:
The origin of this function is in convex programm... |
Assume we have $n$ non-iid standard normal random variables $X_i$. I'm interested in the distribution of $Z=\sum X_i^2$. It is clear to me, that the sum of independent $n$ squared standard normal variables will follow a chi-squared distribution with n degrees of freedom. However, as said above, we assume the $X_i$ to b... |
I have an experiment where I take a set of samples, and test them. If I then take a second set of samples and repeat the experiment, how can I test if there is a significant difference between the sample sets?
More specifically, I take 25 rods of a material and subject them to a breakage test at five different strain r... |
I met a problem in interpreting z values in my GLMM and its post-hoc tests. Since what I am calculating is the counts, I used the poisson family from glmer. and I got a z values of z value = 2.278. But after I put the model into post-hoc analysis ("Dunn" adjustment) with "emmeans", the z value became z value = -3.350. ... |
I'm new to Bayesian statistics. I'm running a linear mixed effects model in R (using lmer), and I want to report Bayes Factors using these results, as demonstrated in Silver,Dienes & Wonnacott (2021). This paper uses a R script version of Dienes' Bayes Factor calculator found here: http://www.lifesci.sussex.ac.uk/home/... |
I have an AR(3)-GJR-GARCH(2,2,2) model. How can I test the presence of ‘leverage effects’ (i.e. asymmetric responses of the conditional variance to the positive and negative shocks) with 5% significance level?
Below is my code for the model:
startdate = '2009-01-01'
enddate = '2021-12-31'
data = yf.download('GD', start... |
I am trying to model the following and would be happy about input/if its correct.
I want to compute a model that checks on differences between Statuses between data sets plotted here on the graph:
The question is: are there significantly more poor/moderate/good statuses in one data origin, in comparison to the other or... |
despite my searching, I cannot find a clear answer to the question:
Do dynamic logistic regression models require data points to be temporally independent?
An answer, an hint and/or a reference would be appreciated, if anyone knows. Thank you.
|
Research Problem
We are trying to help universities recruit as many students as possible for different projects for a good cause. To be eligible for any project offered by their university, students can self-register online via a brief form that asks for contact information and some more data. Some questions are mandat... |
The agent has two actions, a0 and a1, whose effects in each state σ0; . . . ; σ3 are described in Figure 1. The edges from actions are labeled with the probability that this transition occurs. For example, Pr[st+1 = σ2 | st = σ0; at = a1] = 1; similarly, Pr[st+1 = σ0 | st = σ1, at = a0] = 1-p. If there is no edge from... |
x_t=(1+ θL)*ε_t,ε_t ~ iid N (0,σ^2)
What is the long-run variance of x_t? Does it depend on θ? If so, how?
|
I have been studying linear models recently and I'm confused why $cov(Y) = cov(\epsilon)$ holds for $Y = X\beta + \epsilon$. This was just kinda assumed in my course notes
I was looking at this section specifically
|
I'm learning about recommentation systems and I'm trying to build one using item based collaborative filtering approach. I have this dataset in which the lines correspond the items and columns the user. The matrix is filled with the ratings[1, 5] of the items. I chose sklearn.neighbors.NearestNeighbors class to find th... |
I am thinking about a problem in which features comes in batches and in different moments of time/environments.
My current problem set is the following:
Let's say you have n datasets with an arbitrary number of features. Is it possible to set for the boosting optimization to use the first dataset in the first k estimat... |
Yes, this has been asked before here, but for different reasons. In the E-Step nothing is calculated, we simply define the function, yet once it is defined it is defined once and for all. We could even define it in a way, such that it would not need to be redefined in each iteration by accepting a second parameter. It ... |
Suppose that we have a random vector $X \in \Bbb R^n$ and a random variable $Y \in \Bbb R$, and that the joint density $f(x, y)$ is known. For a given $x \in \Bbb R^n$, what is the most efficient way in the statistics community to compute (or approximate) $E[Y| X = x]$?
|
I'm running/ reporting lmer analysis for the first time and have a hypothetical question related to a few of my models. I'm using R lmer package - my models are generally of the formula:
model=lmer(dependantVar ~ continuousVar*catagoricalVar+ (1|Subject), data=data, REML = FALSE);
anova(model)
In some instances, I h... |
Suppose that four variables of $X$, $Y$, $L$, and $C$ have the following relationships in the form of directed acyclic graph.
$X$, $Y$, and $C$ are observable variables while $L$ is a latent (unobservable) variable. If one is interested in modeling the relationship between $X$ and $Y$ through, for example, regression,... |
I have just calculated an odds ratio between the variable vaccine group (experimental and control) and the variable flu (got the flu or did not get the flu). I found the odds ratio to be 0.25. Is it correct to interpret this in the following way?
The odds of developing influenza are 0.25 times less for individuals who ... |
In this example:
what is the third term in attr(,"Pars") within the apVar of the lme object (model.c$apVar in this example)? I know it is related to the correlation of the two random effects, but how is this calculated? How can I calculate this manually from the correlation in the output of VarCorr(model.c)?
|
I would like to simulate a dataset of a Discrete Choice Experiment (DCE) that would be analysed with a simple multinomial logit model. For example, the DCE could concern consumers preferences for two different food items with different attributes (e.g., calories, fat content, price). I was thinking to use a Monte Carlo... |
I'm running GLM(M)s on proportional data ([0,...,1] ) using a binomial family and weighted to number of trials.
ProportionFlowertoPod_Site.b = glmmTMB(PropFlowtoPod ~ Site_ID,
family = binomial,
weights = RepEffort,
data = RepSucPodPlant)
Where PropFlowtoPod is proportion of flowers on an inflorescence that developed... |
The following is the pseudo algorithm for using eligibility traces in Q learning:
In this algorithm, for a given state and action derived from the policy, we get the delta (reward + discounted Q for next state and next action - Q for current state and action). Why do we use the common delta to update all Q(s,a) for a ... |
Using the urca package in R, and the ca.jo() function, I can run a Johansen test and get the test statistic and critical values of the test. However, the function does not return p-value(s). I was wondering how to manually find the p-value given the results from the ca.jo() function, or if there was another package whi... |
Hello I'm new to survival analysis and I have a question about right censored data processing.
For patient B, he survived through the entire study time. Therefore, we need to use the study end date to subtract the study start date to extract the survival days for patient B?
|
Assuming we have the following structural causal model (SCM), with a confounder DAG structure, as follows:
Noise variables:
$$U_1 \sim \mathcal{N}(0,\,1)$$
$$U_2 \sim \mathcal{N}(0,\,1)$$
$$U_3 \sim \mathcal{N}(0,\,1)$$
SCM equations:
$$X1=5 U1$$
$$X2=5 X1 + 5 U2$$
$$X3 =5 X1 + 5 X2 + 5 U3$$
Suppose we observe: $$U1 =... |
I am calculating the CAPM model of BlackRock share price.
In particular the model is:
Rb=return BlackRock
Rf= return risk free asset
Rm = return SP500
Rb-Rf = intercept + B(Rm-Rf)
In my estimation the value of the intercept is not significant. This means that we accept the hypothesis that the intercept is equal to zer... |
I was reading this paper, which uses a sampling attention ($a$ is the net that gives the distribution of attention, $f$ takes the samples and classifies them), and derives the gradient as follows:
Which means that if we consider $f$, we have that the gradient wrt to itself is just the usual one, where instead if we co... |
How does one calculate the p value for a two tailed chi square test with degree freedom of 1?
prop.test(matrix(c(9,17,5,13), nrow = 2), correct = F)
2-sample test for equality of proportions without continuity correction
data: matrix(c(9, 17, 5, 13), nrow = 2)
X-squared = 0.22922, df = 1, p-value = 0.6321
alternative... |
In their original publication, Box and Cox state
...we can obtain an approximate $100(1 - \alpha)$ per cent confidence region [around $\hat{\lambda}$] from
$$
L_\text{max} (\hat{\lambda}) - L_\text{max}(\lambda) < \frac{1}{2}\chi^2_{\nu_\lambda}(\alpha)\ ,
$$
where $\nu_\lambda$ is the number of independent components... |
I have ordinal data on happiness of citizens from multiple countries (from the European Value Study) and I have continuous data on the GDP per capita of multiple countries from the World Bank. Both of these variables are measured at multiple time points.
I want to test the hypothesis that countries with a low GDP per c... |
I'm curious about the basis functions generated by the call to "s()" function with default parameter values, but even more specifically I'm curious about a smoother for a single variable varname that would explicitly have a linear term for that variable (a term perfectly correlated with that single variable on the enti... |
I am running a cox regression for survival analysis using the coxph() function in R for a very large dataset. My model is set up as:
Surv(time,event) ~ age + race + sex +...
The study period is 1 year. We found that age had a different effect in the first six months (phase 1) than it did in the last 6 months (phase 2).... |
I have a response variable that takes on only 5 distinct values: -15, -5, 0, 5, 15. These values are obtained in a clearly categorical manner, meaning: if event A happens, then the outcome is 5, if event B happens, then the outcome is -15, etc... So the eventual response value for a certain observation isn't a result o... |
I am looking at how sex impacts judicial decision making and am trying to balance my dataset where my treatment variable is named "gender.judge" (0 for control group, males, and 1 for treatment group, females). I want to balance the data on these relevant variables: jcs, confirmation year, party, racial minority, and j... |
Question: In the table at the bottom of this question, the total number of times that $\hat{P}(x;z) > \hat{P}_y(x;z) $ and $\hat{P}(y;z)>\hat{P}_x(y;z)$ is 7.
Can someone please replicate this result and explain to me what procedure? they used and why
Note: The table is from Tversky (1972), and
$\hat{P}_y(x;z)$ and... |
Statistics help please!!
I gave subjects a multiple choice test with 3 options.
There were 2 types of questions in the test (easy and hard). The non-correct answer options were either lures or non lures. I'm interested whether the type of question (easy hard) and the type of error the student made (did they pick the lu... |
I am using ggsttaplot - I am curious how to get effect size for each pair:
# install.packages("tidyverse") # for everything ;)
library(tidyverse)
# install.packages("ISLR")
library(ISLR)
# install.packages("ggstatsplot")
library(ggstatsplot)
# stabilize the output of "sample_n()"
set.seed(1)
d <- Wage %>% group_by(... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.