instruction
stringlengths
9
38.7k
So I do think my cox regression residuals are linear. Please correct me if they're not. My reasoning behind this is that the end of the martingale red line "drops off" simply because of few data points and thus, more weight towards the right side. Would you agree? Also, if you wouldn't consider this normal, how would...
Having read articles to try to understand Sufficient Statistics. Sufficient statistics for layman A sufficient statistic summarizes all the information contained in a sample so that you would make the same parameter estimate whether we gave you the sample or just the statistic itself. It's reduction of the data with...
The manufacturers of a certain brand of electrical switches claim that at least $80\%$ of the boxes, containing 12 such switches each, will have no defective. Design a randomized test of exact size $0.05$ based on the number of boxes, among a random sample of 8 examined, containing at least one defective My Attempt G...
Trying to reformulate my question. Let's say i have three statistics from a sample. I have their variances $s_1, s_2, s_3$ and standard errors of the mean $se_1, se_2, se_3$. They are all based on sample size $n$, all from the same population and same sample. I have a metric based on a weighted combination of each of t...
I have some categorical variables that can take values {a,b,c}. I have a dataset of sequences of such variables E.g. x=[ (a,b,b), (b,c,a)...] I would like to apply some basic autoencoder to this dataset. I could derive some meaningful latent space representation by mapping each categorical value to an arbitrary input ...
I saw this question "Storing a probability distribution without saving single values" on stackexchange and thought it deserved a statistical answer. Example Scenario I could see this problem arising if one would like to store a percentile, like P90, on a granular level, but would also like the ability to aggregate to h...
I'm working on a multicenter prospective cohort study investigating the predictive accuracy of a sepsis score (qSOFA) to predict 30-days in-hospital mortality and using Stata 17 ME. The score has four possible values (0–3) and is considered positive when it is ≥2. I'm trying to build a well-mixed-effect model to assess...
Given $f(X_1 \mid X_1 + X_2) \propto \mathbf{I}(X_1 \leq X_1 + X_2)$ where $\mathbf{I}()$ is the indicator function, and $X_1, X_2$ are independent random variables following $expo(\theta)$ with $\theta \geq 0$ Why can it be deduced that $(X_1 \mid X_1 + X_2) \sim U[0, X_1 + X_2]$ where $U$ is the uniform distribution...
I am currently working on a project investigating the impact of investment on wage inequality, where wage inequality corresponds to the average wage in a sector compared to the average wage in the same sector across countries. The question I want to answer is if the sectors that invest increase their wage inequality. B...
I was wondering if any of you could help with how I can somehow plot result from a signal detection analysis in r? I have used the psycho package and calculated dprime, beta, aprime, bppd and c for all participants in two conditions. But I'm not quite sure how to report the result in an proper manner. I would like to h...
I have unit $\times$ time panel data, $x_{it}$. I have taken the time average for each unit: $$\alpha_i=\frac{1}{T}\sum_{t=1}^T x_{it}.$$ How would you calculate $\mathbf{Cov}(x_{it}, \alpha_i)$?
I am conducting logistic regression and got 0.1542 as pseudo R2, and it is based on Mcfadden's. I've searched materials about this, because this is my first time that modelling logit models, and found that it has been mentioned 0.2~0.4 means 'excellent fit'. Then can I think that it is very difficult getting high value...
I am working on a probability problem to solidify my knowledge and running into some difficulty. I have the following setup: Let $W_{i}, W_{j}$ represent 2 i.i.d random variables, drawn from $N(0,1)$. $W_{i}$ and $W_{j}$ represent the individual skill of 2 chess players, $i$ and $j$ respectively. Let $v$ ~ $Laplace(0,...
Consider the Bernoulli random variable $Z$ that takes $z=1$ with probability $1/2$ and $z=0$ otherwise. A different random variable, $X$, is defined on $x \in [0,1]$ has the following conditional distribution: $$ f_{X|Z}(x|z) = \left\{ \begin{array}{lc} 2x, & z=1 \\ 2-2x, & z=0 \end{array} \right. $$ (A realization of ...
I am working on a task in which I need to classify binary labels 0 and 1 properly (as close to perfection as possible). My final dataset (ready for classification) has input data with 141 features and binary labels. The original data is a time-series data generated using inductive sensor and the features are extracted ...
I want to estimate as good as mathematically possible the necessary time ($t_n$) for processing a given input file. The estimation should be a function of the current file size ($s_n$) and all the previous $(s_i, t_i)_{i=0\dots n-1}$ file size --- processing time pairs. The input files are of the same type. Is it there...
At the end of the cross validation of a multi layer peceptron, do we make the mean of the validation results of the last epoch of the model on each fold or do we make the mean over all the errors? For instance, suppose i do a 3-fold cross validation ona neural network and i get 1st fold: 300 epochs and 0.5 of error in ...
Consider the binary classification problem where class label Y ∈ {0, 1} and each training example X has 2 binary attributes X = [X1, X2] ∈ {0, 1}^2. Assume that class priors are given P(Y = 0) = P(Y = 1) = 0.5, and that the conditional probabilities P (X1|Y ) and P (X2|Y ) are given as follows: Assume you want to est...
Is there a version of the Metropolis-Hastings algorithm where either the proposal kernel; or the acceptance function might depend on the whole history (or at least a part of it) of the chain so far? For example, the papers Adaptive proposal distribution for random walk Metropolis algorithm and On an adaptive version ...
Im currently working on a meta-analysis of randomized controlled trials, which examine the use of a certain graft in certain surgical intervention. In my pre-specified protocol, I planned to perform a subgroup analysis based on the thickness of the graft. So the subgroup analysis was planned to be having two groups onl...
Goal: To find all critical variables that influence time to death so as to not record unneeded variables in future observations. Call: coxph(formula = Surv(time, DEATH_EVENT) ~ age + anaemia + creatinine_phosphokinase + ejection_fraction + serum_creatinine + serum_sodium + hypertension, data = HF) ...
Would someone mind telling me if my working for the following problem looks reasonable? An astrophysicist studying the expansion of the universe has a set of redshift measurements, each covering the same section of the Milky Way. If current theory is correct, redshift should be close to zero. (i) Let $x_i$ be the $i$-...
I've seen in multiple papers that use a relaxation of the Bernoulli distribution as defined in Maddison et. al (here it is referred to as Binary Concrete) and they say that a closed form solution for the KL divergence between two relaxed Bernoulli distribution exists, but I can never find the explicitly stated solution...
When it comes to categorical variables, they should only be converted to dummy variables if the nature of the categorical variable doesn't have any sense of structure (such as: high, medium, low). Meaning that a categorical variable that includes: Tea, Soda, Coffee, Water is a good example of a categorical variable tha...
I have survey answers for a questionnaire that contains 8 separate questions, where each has a number of (categorical) choices, as well as data on the respondents' characteristics (age, professional status, etc..). The data is presented like this : where hh stands for household, AGECHEF for agegroup, and the varc vari...
I have a data set with 360 observations. I run a glm with a gamma family, and I want to show that I fail to reject the null hypothesis. Although the p-value greater than 0.05 is kind of showing that but I was asked to report the power of my test. I wonder if it is right to use cohen's d for multiple regression (f-test)...
I have performed a study evaluating the diagnostic performance of a new test (T) (binary outcome) for a disease (D). Logistic regression was performed with the disease state as a dependent variable, the performance of the new test (T), and a few previously published potential risk factors were used as the independent v...
I have data that I would like to model with a product distribution (of two independent random variables). The product distribution is being adopted because there is reason to believe that the variable being measured empirically is a ratio of two variables (or the product of one variable and the reciprocal of the other)...
Let a random variable with posterior distribution be given by $X \sim \textrm{Gamma}(10,12)$. This is the result of Jeffreys prior $\pi_J(\lambda)$ multiplied by the Likelihood of i.i.d. $X_1,...,X_n \sim \textrm{Exp}(\lambda)$. Also, $n=10$ and $\sum_{i=1}^{10} X_i = 12$. I'm trying to compute a one-sided Bayesian con...
I wish to test whether a large number of observations $X_i$ follows an exponential distribution with parameter $\lambda=1$. I also wish to test this hypothesis exactly, and intend that if the observations follow an exponential distribution with a different parameter, the test should reject the null hypothesis given suf...
I am learning about bayesian experimental design and confused about the "Bayesian" terminology. Multi-armed bandits are normally in the syllabus of bayesian experiments. But there are techniques like Thompson sampling which uses bayesian optimisation and there are also non-bayesian bandit algorithms. So my question is:...
Hi, The above image is from "Latent Variable Models" by Loehlin and Beaujaean. Given the model above the structural equation for Y is, Y = cX + dZ + e*XZ + W. So it's an interaction model. My question is as follow. Why is the covariance betwen X and Z (i) included in the model despite the presence of the interaction v...
I couldn't grasp what it refers to exactly so I would like to understand how we use it: from MLE, Score Vector is: $$ S(\theta;y) = \frac{\partial l(\theta;y) }{\partial \theta} $$ $l$ comes from the log version of the likelihood function and this score vector has an asymptotic distribution with Information Matrix whic...
I'm confused with the concept "stationarity". Reference: https://otexts.com/fpp3/stationarity.html I believe random walk is non-stationary and change (difference) in random walk is stationary. The characteristics of random walk are these below: long periods of apparent trends up or down sudden and unpredictable chan...
Continuing from my previous question here. Furthermore, I intend to perform the chi-squared test and plot QQ-plots to test the hypothesis $H_0:\lambda=1$. I do not get to see the actual data though; I have only the test result as well as the plot. I want to believe that the data may actually be generated from a geometr...
I am trying to fit a mixed model for repeated measures. My experiment has subjects divided into two groups, with the dependent variable (DV) measured twice for each subject, like so: subjectID time group DV 101 pre subject 24 101 post subject 85 102 pre control 32 102 post control 24 etc ... ... ... ...
According to adf test, the data set is non stationary but the best arima model is (1,0,2). However, non stationary data set must have d value differ from 0, right?
I have been reading around ridge regression and have come across two forms of $\hatβ$ in textbooks. Am I correct in believing that $(X^TX+\lambda I)^{-1} X^TY$ is the same as $RSS + \sum_{j=1}^{p} \beta_j^2$? Also, if they are equivalent, how is the best way to picture this?
Basically from what i learned, I can use F-test to test for joint hypothesis. But if we have a regression model $y = \beta_0 + \beta_1 x_1 + \beta_2 x_2 + \beta_3 x_3$ , and the null hypothesis is $\beta_1 = \beta_2, \beta_3= 0$, what test statistics can we use for this simultaneous test?
If one variable is correlated to other 73% or between (70% to 75%) does it should be considered as multicollinearity and shall I exclude one of the variable from linear regression model ? I will be very thankful if you also provide justification of your answer.
I am fairly new to (the eye-opening world of) Bayesian inference and machine learning and I am stuck at a inference problem that is important to my current research, where I want to introduce Bayesian thinking into the field. I want to estimate a the psoterior for a variable V that must remain positive. Now, first i wa...
Our training data will either be linearly separable or non-linear separable. In both cases the decision boundary is defined by: $$ f(\mathbf{x}) = \mathbf{w} \cdot \mathbf{x} + b = 0 $$ and we classify them based on the value of $\sigma(\mathbf{w} \cdot \mathbf{x} + b)$. If this value is greater than 0.5 then the we cl...
I have a small data set which (a) is always positive and (b) is showing a right tail on the histogram. I wondered if it could be log-normal and tested for this, but to no avail. I am now wondering if it is Rayleigh distributed. Is there a standard test (either quantitative or qualitative) that I can use, preferably ...
Why do anova(lm( )) and summary(lm( )) (in R) yield different p-values for a factor f with two levels? The model is y ~ f + c, f has two levels (unequal sample size) and c is numeric. set.seed(123) df <- data.frame( y = rnorm(1000), f = sample(c("a","b"), 1000, replace=TRUE, prob=c(.2,.8)), c = rnorm(1000) ) fi...
I have 3 independent variables (eg - weight, height) and want to predict the change in another parameter (dose) with the change in the independent variables. The data is collected from patients who are undergoing treatment for cancer. The collected data include the weight, height and other patient parameters. Based on ...
I have a dataset with skewed distributions describing different samples' total variation. I know these distributions are a sum of a normal distribution (analytical variation, which I know) and a skewed distribution (biological variation, which is unknown). So I am looking for a general solution to approximate the biolo...
I am given a model and need to calculate the unit-root of $X_t$ but it seems that there is no unit-root. The model is given: $X_t = (x_{1t},x_{2t})'$ $$\Delta X_t = \alpha \beta ' X_{t-1} + \epsilon_t $$ \begin{align} \alpha &= \begin{bmatrix} -0.50 \\ 0.25 \end{bmatrix} \end{align} ...
I am doing model selection and really confused about why the significance of the coefficient is different from ANOVA, which the coefficient is significant using the summary function, but when I put it into ANOVA, it shows it is not significant. Could you tell me which one should I follow. Here is my code: model1 = lm(I...
Estimating the following model in Stata helped me get the direct effects. This is a set of three models, a beta regression with the final outcome as the dependent variable, and two mediating negative binomial regressions. I've not been able to write the same model using lavaan or mediation packages in R, because lavaan...
Suppose $p(x) = \lambda e^{-\lambda x}$. However, our probability of observing a given sample of $x$ (denoted $z$) is further proportional to $x$ itself, i.e., $p(z\mid x) = \lambda e^{-\lambda x}$. What is $p(z)$? In R, I can characterize the distribution empirically: n = 1e5 r = 0.1 x = rexp(n,r) z = sample(x,n,repla...
I've been reading through lots of university lecture slideshows and various websites describing belief propagation. I'm not a math person, so it's really tough to understand the formulas and they don't always seem consistent. For instance, some don't seem to mention conditional probability tables. I've really been tryi...
Let $Y=a(X-b)^3+\epsilon$ where $\epsilon \sim N(0,\theta^2)$ is independent of $X$. I know that the conventional regression function of $Y$ given $X=x$ is expressed as $$f(x)=\mathbb{E}[Y|X=x]$$ What other ways can this regression functions be expressed as? Namely, is $f(x)=a(x-b)^3$ also a valid regression function o...
On the BorutaPy GitHub page, the authors state: "We highly recommend using pruned trees with a depth between 3-7" (https://github.com/scikit-learn-contrib/boruta_py). What justification is there for using a depth in this range? I've seen this recommendation reiterated many times by others citing the BorutaPy authors wi...
Assuming that the design matrix is of full rank, in non-degenerate cases of the logistic regression model, does the maximum likelihood estimator always exists and is always unique? It would be really helpful if someone could provide an example or a resource link.
Going through the top answers in How can top principal components retain the predictive power on a dependent variable (or even lead to better predictions)?, I understand that doing PCA and keeping the top k components may or may not improve classification performance of some supervised learning algorithm. For decision ...
I have an ANOVA model with 3 effects (A, B, C) with (a, b, c) levels each and 3 two-way interactions (AB, AC, BC). Within each cell there are n replicates. How to calculate number of degrees of freedom associated with each sum of squares, residuals, in particular? I have two ideas: It is either the difference between ...
I'm running a survival analysis on a sample of 26 patients, divided into 2 groups according to certain variables and different times ( because there is censored data). I couldn't perform the log-rank test because of the small sample size, so I'm thinking of performing a Fisher's exact test. What should be the best test...
Consider a distribution with parameter $\lambda$ that has density $$f_\lambda(x)=\frac{x^4}{24\lambda^5}e^{\frac{-x}{\lambda}},x>0$$ Let $X_1,...,X_n$ be $n$ independent random variables drawn from this distribution. I test the hypotheses $H_0:\lambda=1$ vs $H_0:\lambda≠1$ by using the test $$\psi=\textbf{1}\big(|\bar{...
If the predictor $X$ in a simple linear regression $Y = \beta_{0} + \beta_{1} X + \epsilon$ is measured with error, the OLS estimator for the predictor's coefficient will be biased towards zero. What is the corresponding effect on the posterior of $\beta_1$ in a Bayesian setup? Is there (only?) an analog effect on the ...
I was wondering if there is a fast heuristic algorithm for performing grouped stratified dataset split on a multilabel dataset. Question originally posted on Data Science stackexcahnge here. Stratification is usually performed to ensure balanced label distribution in train, val, and test splits. This post describes how...
cox.zph(coxph(Surv(time, DEATH_EVENT) ~ age+anaemia+creatinine_phosphokinase+strata(ejection_fraction)+ serum_sodium+serum_creatinine+hypertension, data=HF)) What exactly am I doing when I am applying strata() to ejection_fraction? From some research, I've found that stratifying simply creates groups o...
I am testing for proportional hazards in my model. Time-Dependent Model cox.zph(coxph(Surv(time, DEATH_EVENT) ~ age+anaemia+creatinine_phosphokinase+time:ejection_fraction+ serum_sodium+time:serum_creatinine+hypertension, data=HF)) chisq df p age 0...
coef exp(coef) se(coef) z Pr(>|z|) hypertensionPresent 0.417717 1.518491 0.209708 1.992 0.0464 * age 0.042424 1.043336 0.008693 4.880 1.06e-06 *** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 exp(coef) exp(-coef) lower .95 ...
We were studying linear regression: $$Y = \beta_0 + \sum_i \beta_ix_i + \varepsilon.$$ We were then doing hypothesis tests: $$H_0\text{:}\; C\beta=0 \\H_1\text{:}\;C\beta \neq0.$$ Under the assumptions that: Data follows GLM $\mathbf{Y} = \mathbf{\tilde{X}}\beta + \varepsilon$, with rank$\left(\mathbf{\tilde{X}}\right...
I am trying to understand the difference for training RSS and test RSS for smoothing splines e.g. $$\hat{g}=\arg \min_g \left(\Sigma_{i=1}^{n}(y_{i} - g(x_i))^2 + \lambda \int [g^{(m)}(x)]^{2}dx \right)$$ for $m\in\{0,1,2,3,4\}$ which one has a bigger training RSS and test RSS, as $\lambda\rightarrow\infty$, and when ...
I just wanted to verify that this is true. Say the .95th quantile of a random variable, $X$, is $q$. Then the .95th quantile of $\frac{X}{k}$ is $\frac{q}{k}$ where $k$ is a constant. I am assuming this property holds. $$ P(X*k > x) = P\left(X > x * \frac{1}{k}\right) $$
This is a slightly modified version of a programming question that I asked in that forum and was redirected here to get a better sense of the statistics involved. https://stackoverflow.com/questions/74839826/how-can-i-pass-a-time-series-consisting-of-both-mean-and-se-to-the-predict-funct/74840556?noredirect=1#comment13...
I have clinical data from about 300 patients with repeated measures/observations of psychological distress over time. Psychological distress is measured as a continuous variable, but could be converted into a binary or categorical variable if necessary. About 60% of patients have only 2 observations and the rest have 3...
I wanted to write the mathematical equation for my model below. It is a glm that tries to explain the relationship between the sum of observed biomass of several replicas at different observation sites as a function of distance from a given point, plus the random effect of the sites. I also use the Gamma family. I used...
I am trying to fit an AR/ARIMA model on electricity data on hourly prices during a almost three year period, I am following the guidelines in Hyndman, R.J., & Athanasopoulos, G. (2018) to do this. This post is about understanding the histograms, ACF and PACF, and what the Differencing do to these graphs. My prices are ...
I have this study design: two groups (A & B) measured in 3-time points (pre, follow-up & post). I thought that a linear mixed model effect was the preferred option because I do have missing values at random instead of using repeated measures ANOVA. Here is an example of my model: m0<-lmer(VD ~ Group*Time + (1|ID))#line...
I have the following pdf with support $x>0$: $$f_{\mu}(x)=\frac{1}{\sqrt{2\pi x^3}}\textrm{exp}\left(-\frac{(x-\mu)^2}{2\mu^2x}\right)$$ This belongs to the exponential family, and I write this in the following form $$f_{\mu}(x)=h(x)\space\textrm{exp}\left(\spaceη(\mu)T(x)\space-B(\mu)\right)$$ What I have thus far is ...
Let $X_1,\dots,X_n\overset{iid}{\sim}F_X$ be random variables. Let $b\in(0,\infty)$, and consider the transformation: $$ Y_i=bF_X(X_i)\\ i=1,\dots,n $$ How do I calculate the order statistic $Y_{(n)}?$
I'm using scipy's optimize to fit two Gaussian distributions to my data. I expected the posterior likelihood of belonging to the rightmost class to start from 0 before the distributions cross, and go to 1 from that point. However, the output looks like this, so the probability of belonging to the second class is high ...
I am working on some data that I would like to analyze through a generalized linear mixed model regression and a stepwise backward selection of variables directly on that model. I use the GLMERSelect R package which seems developed exactly for this purpose. In this function, you specify the response variable (responseV...
Given a softmax output layer, what does it mean to "follow the gradient"? Usually that would consist in "increasing the output" but obviously the softmax has no notion of "increasing the output" since it's normalized So, I was wondering what actually happens following the gradient of a Softmax layer, and my take is tha...
I want to restrict values s.t. I get $\theta = (\alpha, \beta) =g(\theta_1, \theta_2)$ with the following restrictions. $ 0\leq \alpha \leq \beta <1 $ I know the correct answer should be $\beta = (1+\exp^{-\theta_2})^{-1}$ and $\alpha = \beta(1+\exp^{-\theta_1})^{-1}$. However, when I make the system of equations, some...
I've seen quite a lot of conflicting views on if one-hot encoding (dummy variable creation) should be done before/after the training/test split. Responses seem to state that one-hot encoding before leads to "data leakage". This example states it's industry norm to do one-hot encoding on the entire data before training/...
I have customer purchase history data which has variables like recency, frequency and monetary value. Like any business, most of our revenue comes only from 20% of the customers. So, our distributions for each of the variables are skewed. As I intend to use them in k-means algorithm for clustering, I wanted to do the b...
I am running a probit regression model to test my hypothesis. As one cannot deduce the magnitude of the effect of the independent variables on my dependent one, I have calculated the average marginal effects of my regression. My problem is, that there are AME in the output table (I used margins(regression) to calculate...
I have been trying to use nhanes data to do a mediation analysis. The main model is a logistic regression model. I tried the mediation package first, but it can't use the weights of the nhanes data. I also tried the lavaan.survey package, but it doesn't fit a logistics regression model. Which R package should I use?
I am working on the movement of fish from the centre of a protected area to a non-protected area. Based on the article by R. Abesamis, I applied to my dataset a logistic decay $D = 1/(1+\exp(S\cdot (I-d))$ where $D$ is the proportion of biomass in the middle of the reserve, $d$ is the distance from the centre of the pr...
I am considering a simple decomposition of share prices, in an attempt to calculate idiosyncratic price movements. Suppose we have a stock with price $S$. Then, one can think about the price as follows: $$ \Delta S = \beta_1 * \Delta M + \varepsilon_1 $$ Where $M$ represents "market-wide factors" (say the change in the...
I am trying to find out whether the regime type of states signing international cooperation agreements influence the design of the agreement, more specifically whether the regime type of the members leads to the use of escape clauses. I will solely focus on bilateral agreements, so there are always and only two states ...
I have to analyse a 2x2 AB/BA crossover study, in which every participant was administered drug A and then no drug at all, or vice versa. There were two study visits and in each visit the peak glucose values after an oral mixed meal test were taken for each participant. I am confused about the type of t-test I should u...
Is there an intuitive way to remember if we get an upper bound or lower bound for a parameter when inverting a one-sided hypothesis test? In Casella & Berger, it is written: If we have $H_0: \mu = \mu_0, H_1: \mu < \mu_0$ then "$H_1$ specifies 'large' values of $\mu_0$, so the confidence set will contain 'small' values...
I am currently conducting a meta-analysis about the effect of blood parasites on different fitness parameters of song birds. Since I have a rather large number of parameters that I want to incorporate, I decided to use a standardised effect size (Cohen's d). Whenever possible I am using the mean+SE or SD of the two dif...
I'm using Multilayer Perceptron ANNs at the very beginning of my project (it's a binary classification problem). Because it's simpler, I started with Scikit-learn. I got a magic result, with my model classifying correctly 98% of the test set. Now, I want to move to TensorFlow so I can implement other details, use dropo...
I'm studying machine learning and every book I open I bump into chi-squared distribution, gamma-function, t-distribution, Gaussian, etc. Every book I have opened so far only defines what the distributions are: they don't explain or give the intuition on where the specific formulas for the functions come from. For examp...
I am running a cox-regression model and am struggling with how to define my survival time to event (heart failure) if their time to HF (=1) AFTER they have died? i.e. it is documented they have a case of HF, but this is AFTER the date of death/ this person dies before developing the event. Variables: . HF: binary (1 = ...
Working through a lecture exercise on MCMC methods. I have a dataset containing the outcome of N chess games $-$ in the format Winner, Loser $-$ between M players. When 2 players $p_1$ and $p_2$ play against one another in game $g$, the outcome is modeled as $y_g = sign(W_{p_1} - W_{p_2} + v_g)$, where: $W_{p_i}$ repr...
Hi! The above image is from "Latent Variable Models" by Loehlin and Beaujean (p.154). There are two groups: high stressor group and low stressor group. The image describes the path diagram for high stressor group but basically its the same for the low stressor group. The triangle 1 was added to compare the means of th...
I tried applying splines to my model and that increased the p-values for all other variables in my model. Instead, I chose to categorize my continuous variable, ejection_fraction. HF$ejection_fraction = cut(HF$ejection_fraction, breaks = c(0, 40, 50, Inf), labels = c("Critical", "Borderline", "Normal")) finalMod <- co...
I am evaluating linearity on Serum Creatinine for Cox regression. It seems to be influenced heavily by 2 points in the middle. Is this okay or should I look into transforming? X <- HF$serum_creatinine Y <- resid(reducedMod, type = "martingale") plot(X, Y, pch = 20, col = "darkgray", xlab = "Serum Creatine", ylab ...
I am doing survival analysis and was wondering if there was a name for the following expression: $$H(t)=\int_{0}^{\infty}{g(t) \cdot S(t) \cdot dt}.$$ It appears to be very similar to the equation for computing the expectation w.r.t. a pdf only with the complementary cdf instead of the pdf.
I'm running simulations for a power analysis for a negative binomial GLMM. The dependent variable has a negative binomial distribution and will be measured at five time points. It has two other characteristics I'm not sure of the most appropriate way to simulate. First, it has a maximum possible range of 0 - 128. Secon...
I applied a logistic regression using the nlmrt package to describe the relationship between biomass and the distance and site variables. I got this result, but I am not sure to understand the p-value of the parameters. Do these results mean that my model describes the variation of biomass as a function of distance in ...
Following is a normal distribution equation: $$q(\mathbf x_t\mid\mathbf x_{t-1})=\mathcal N(\mathbf x_t;\sqrt{1-\beta_t}\mathbf x_{t-1},\beta_t\mathbf I).$$ I understand there should be mean and variance in normal distribution. But what is the meaning of this? It contains three variables.
Suppose I have data with the following format: Date_DMY age_bracket Num_Infected Total_Infected Total_Prop_Infected 1/1/2000 30-39 1 1 0.0524 2/1/2000 30-39 2 3 0.1149 3/1/2000 20-29 3 6 0.1657 3/1/2000...
This is my spline model which does satisfy proportional hazards. I created this due to being advised against categorizing my variable. I arrived at the variables (without splines) by "backward" stepwise reduction which I heard makes the p-values not valid. Can I still use this spline model despite having some p-values ...