instruction
stringlengths
9
38.7k
I recently saw a case where someone fit a SEM with 20 latent variables (with many indicators each) predicting a single latent variable (of several indicators), and suggested it was evidence for some causal/theoretical model and called it a day. There were no indirect paths and they did not have multiple outcomes/DVs (...
Consider a random variable $X$ with density $$f(x : θ) = C(θ)e^{η(θ)T(x)}h(x), θ ∈ Θ$$. Assume that $η(θ)$ is strictly increasing in $θ$ and that the family is full rank. Show that there will not be any UMP size $0<α<1$ test for $H_0 : θ = θ_0$ against $H_1 : θ \neq θ_0$. $$$$My attempt to the solution is as follows : ...
I have a multinomial Naive Bayes model that classifies a document into 1 of 178 classes. This goes well about 50% of the time, so it's pretty good (for my use case) considering the large set of classes. Now, I want to know if by knowing the size of the input document (in bytes) I can say anything about the confidence o...
I ran a multilevel logistic regression model using function glmer from R package lme4. All of my predictors are binary and I have used effect coding, i.e., coding -1 and 1. The model contains multiple interaction terms. I have computed odds ratios, but struggle to interpret the model's interaction effects. I know that ...
Consider independent random variables $X_n\sim\operatorname{\mathsf{Ber}}\left(\frac1n\right)$. The problem is whether $$X_n\xrightarrow{\mathrm{a.s.}}0$$ is true or not. I tried to use the definition $$\Pr\left(\lim_{n\to\infty}X_n=0\right)=1$$ But I do not understand what the limit of those mean. I read that it can b...
The question is about computing the variance of the random-effect parameters estimated when fitting a linear mixed-effect model when the parameterization of the random-effect parameters changes. This link describes how to use the delta rule to compute the variance of the estimated random effects. I would like to exten...
Consider $n$ samples $X_1,X_2,..,X_n$, where each is normally distributed according to mean $\mu$ and variance $\sigma^2$. We use these samples to define our reference population. Given a bootstrap sample from this reference population, i.e., $Y_1,Y_2,...,Y_n$, we know that the mean $\bar{Y}$ has expectation $\mu$ and ...
I have found that random effects terms can affect other coefficients within a model from here. I see how in this example the coefficients change with the addition of a random effect; I'm still not sure why this happened though. I've seen how the Frisch–Waugh–Lovell theorem can show how coefficients may change in respon...
My data consists of three columns A is the percentage of those who answered 'Yes' on question 1 B is the percentage of those who answered 'Yes' on question 2 C is a number that represents a score. This score is an index that is NOT calculated based on the previous columns. It is kind of rating for this group. I want to...
Short Version: Given a variance covariance matrix for my multivariate normal distribution where the entries are equations of other parameters, how do I find which of those parameter values maximizes the likelihood of my data? I've tried treating the function which calculates the likelihood of my data like a black box a...
In a random sample of n subjects with n being very large, let X be the number of successes. Now I want to create the confidence interval for the natural log of the proportion of successes. Can I simply log the confidence interval I would get from applying CLT on the proportion estimate? This should be possible as quant...
I am developing Machine learning prediction models using the caret package in r (Elastic net, SVM, Random Forest, XGBoost). I have 650 cases with 104 having the event of interest. Instead of splitting the data into training and test cohorts, I have decided to use .632 bootstrap to perform internal validation. First I p...
Many papers design a methodology to detect a difference between $2$ groups regarding a primary outcome. This result is then given a $p$ value to denote statistical significance. Some papers then go on to adjust their analysis for age, sex, weight, height etc., and report a statistically non-significant difference betwe...
I am unsure how to best control for baseline levels in a mixed effects models. I've seen several different suggestions and I'm not sure if one option or more correct or appropriate than another. Lets say I am running analysis for longitudinal study with 3 treatment groups (group 1, group 2, group 3) and three time poi...
Past the standard full factorial and fractional designs, I am getting the impression that non-regular designs (OME, Hall, mixed-level OA, etc.) are just trying to fit in as many factors as possible. This implicates the later regression analysis. Assume $X_{n*m} $design matrix, the overall degree of freedom would be $n-...
In simple linear regression with one regressor, if you regress $y$ on $x$, i.e., $\hat{y} = \hat{\beta}_1 x + \hat{\beta}_0$ and $x$ on $y$, i.e., $\hat{x} = \hat{\alpha_1} y + \hat{\alpha_0}$, you can show mathematically that $$ R^2 = \hat{\beta}_1 \hat{\alpha}_1 $$ Is there an intuitive explanation for how the coeffi...
It makes sense to me that we can use the ROC-AUC and PR-AP scores of the validation sets during CV to tune our model hyperparameter selection. And when reporting the models final performance, it makes sense to create a PR or ROC curve on the test data set to illustrate performance on unseen data. But in terms of select...
It seems more natural to talk about UMVUE (following the basic statistical estimation theory). But when we turn to lm, we only care about BLUE, why? Are there any insurmountable difficulties here?
I'm trying to do a multiple linear regression analysis in Excel using the Analysis Toolpak and I am not good at math, let alone stats. So please excuse my total ignorance. I'm using the following explanatory variables: Median income in dollars per county Number of people below poverty level per county Number of reside...
When computing the mean squared error of a regression model, we get a metric in square units. For ease of interpretation, we can therefore instead compute the root mean squared error, which are in units of the target variable and also in a value range that is is closer to the actual values that we are predicting, and h...
I'm working on a Machine Learning classification problem that has five Service Spending features (among many others) in its dataset, each sample is a customer. For instance, here are the first three customers for these features: Service 1 Service 2 Service 3 156 0 0 564 42 0 0 100 140 I've used these nu...
I'm looking for good or reputable references (books, articles, possibly documentaries, instructional videos, podcasts or radio shows, etc.) directly related to the history of ethics in statistics. The kind of references I'm looking for include: Biographies or accounts of historical events, ​prominently involving ethic...
The Wikipedia article on Barnard's test says: While first published in 1945 by G.A. Barnard, the test did not gain popularity due to the computational difficulty of calculating the p value and Fisher’s specious disapproval. Are there other examples like this one, where non-technical reasons led (at least in part) to ...
I'm working on the topic of causal inference, I use time-series data. I have two scenarios in front of me and I don't understand the difference: Given X and Y "time" features. I would like to know whether X, e.g. average income, does it cause Y, e.g. hotel reservations. Given X "time" feature and an intervention. I'm ...
I am trying to understand the vector-autoregressive error correction model, but I am having a hard time understanding the error correction part. Imagine that we have a VAR(1) model of 2 dimensions: $$\left(\begin{array}{c} \Delta Y_t\\ \Delta X_t\end{array}\right)=\left(\begin{array}{c} \alpha_Y\\ \alpha_X\end{array}\r...
I have some difficulties in understanding the validity of the paired difference tests. Indeed, considering the Wikipedia article about that, it's written that $${\rm var}(\bar{D})= \sigma_1^2/n + \sigma_2^2/n - 2\sigma_1\sigma_2\operatorname{corr}(Y_{i1}, Y_{i2})/n$$ with the additional justification that correlation ...
I am estimating a difference-in-difference model estimating the effect of a parental leave reform on female wages. It is not possible to take the logarithm of the varaibles as a lot of wages are 0. I am therefore transforming the varaibles into percentage change by dividing with the average of the control group after t...
200 people were tested, 20 of those were infected. I want to get a posterior distribution for the uncertainty associated with the probability that a person is infected. I do this like this: n<-200 s<-20 p<-seq(0,0.3,0.001) dp<-dbeta(p, s+1, n-s+1) But then when I plot it, I don't know how to interpret the y axis and ...
I have followed this post and tried to see if there will be any difference in predicted probabilities if I use different one-hot encoding in XGboost. This is my code with some dummy data, which is actually not ordinal in nature. from xgboost import XGBClassifier from sklearn.datasets import load_iris import pandas as p...
I have a problem with some health data that I'm trying to analyze. The main issue originates from a census variable is derived from self reported times. The variable is sleep duration, which is derived from the hour reported at which the survey-taker goes to sleep, and the hour at which they wake up. The documentation ...
I have computed a (online) sample size calculation for mean difference between two groups. The calculation was done with the following data from literature: The website used for the sample size calculation is: Sample Size Calculator (clincalc.com). This gave the following calculation with the data provided by literatu...
This is a follow-up question on this post It uses a term 'edge'. For example, it says I understand that extrapolation is harder than interpolation. And I understand that if we choose a point to predict and it happens to be near the edge of the sample space, we are more likely to have to extrapolate. But a large part o...
I want to analyse the effect of media coverage on the increased risk of thrombosis associated with combined oral contraceptive use. The peak of media coverage happened in late May 2015. The plot of the data is shown below. I assumed awareness of the increased risk would cause the sale/use of the combined pills decreas...
I'm learning about the theory of estimators and saw that sometimes the analytical formula of the estimator has to be diferent off the formula for the parameter, for example the standart deviation, and is sometimes difficult to get a good estimator. Can I in this cases just use bootstrap in the sample with the same form...
I have started a project in order to develop my coding skills, where I am predicting next month's S&P500 return direction based on some macroeconomic and financial variables. These datasets have monthly data. I have downloaded the data, cleaned and applied some transformations: -For financial variables I have taken the...
Let $x \sim U[0,1]$ and $y\sim U[0,1]$. Let $z= \omega\, x+ (1-\omega)\,y$, where $\omega\in[0,1]$. The pdf of $z$ is a trapezoidal distribution over $[0,1]$: \begin{equation*} \begin{aligned} f(z)&= \left\{\begin{array}{cl} \dfrac{z}{\omega (1-\omega)} &\text{if}\,\,\,z \in[0,\min\{\omega, 1-\omega\}] \\[0.08in] \df...
I have watched a video describing the differences between Cluster Analysis and Mixture Models. https://www.youtube.com/watch?v=HwsMZwhO7wU&t=2s Clustering determines compact clusters and assigns people to those clusters. Clusters cannot be overlapping and are entirely discrete. Mixture Models such as LCA are probabilis...
One of the cohort studies I have carried out recently involved examining the association between post-diagnostic beta-blocker use and breast cancer outcomes in a cohort of breast cancer patients. Briefly, I followed patients up from their breast cancer diagnosis until death or end of 2017, and treated beta-blocker use ...
Let $X_i$ for $i = 1, ..., n$ be a random sample from the distribution $N(\mu, \mu^2 \tau)$ with unknown parameters $\mu \in (\infty, 0) \cup (0 ,\infty), \tau > 0$. Find and justify the mle $\hat{\tau}$ and the limiting distribution of $\sqrt{n}(\hat{\tau} - \tau)$ as $n \rightarrow \infty$. My Solution: So from expon...
There are two approaches for estimating the Kendall-Theil-Sen intercept b0. Approach 1 β0 = Median{yi - β1*xi : 1 ≤ i ≤ n} Approach 2 β0 = Y_median - β1*X_median where X_median is the median of the x values and Y_median is the median of the y values Given Dataset x 8 26 29 30 32 34 35 36 37 39 y 33 15 2...
I'm looking to understand what would be the most appropriate R model for fitting a clinical dataset in which the dependent variable is the change in a 5-point scale and the end of treatment. The data has the below variables and form, question under 's2_improv': arm - 2 level factor - 'trt' for treatment, 'p...
Previously I've successfully performed support vector classification with recursive feature elimination in R using the e1071 package, but I'm now hoping to move over to SciKit Learn given that Python has much better support for machine learning than R does. I am fairly new to Python and very new to sklearn. My classifi...
This isn't a question where I have a code example to provide. It is more of an informal question about what to do between 2 options. Assume I have some data and my goal is to fit a model using the lasso algorithm and I want to select a model based on the OOS MSE score. Which of the 2 approaches below is correct? Split...
I am new to R and am trying to build general linear models with multiple categorical and continuous predictors using the lm() function. My models also have some interactions of the different categorical variables Since I am learning R, I like to verify my results in JMP as I perform my analyses. In short, when I build ...
I'm first learning about backpropagation in neural networks. We're doing stochastic gradient descent. The lecture provides incomplete detail on computing the derivatives for the final layer. We have the following chain rule equation for the partial of the change in the error as a function of a given weight: $$ \frac{\...
I've implemented an optimization algorithm to optimize the revenue of a particular store. I've done this for my 2020-2022 data. Moving forward, what I aim to do is to predict the difference (% increase or decrease) between my normal revenue and optimized revenue. I've done linear regression, GLM, GAM, and regression tr...
I am trying to understand the ramifications of this three-way distinction, particularly when it comes to model building. Could someone point me at the standard references on the subject?
Does learning thorough statistical theory requires learning analysis before that? I looked at the textbook for statistical theory. So far I don't know if analysis is required, but I think I have heard analysis is a prerequisite. Should I learn analysis beforehand?
I have a dataset with a categorical target ($y$) and multiple categorical features ($x_1$, $x_2$, ..., $x_i$). I have been able to successfully use a logistic regression model to calculate an odds ratio for each feature individual. I was wondering what metric is traditionally used for groups of categorical features tog...
I want to know how to use Poisson GLMMs when we have unequal samples available for different groups/clusters/participants in data. Imagine a study where each of the 60 participants are given 1000 medicinal leaves and are asked to report the number of leaves (count) they eat on each day for the next 20 days from the beg...
I'm looking at patients that have attended a pain clinic for assessment and treatment program. I want to look for differences between the population that complete the program and the non-completers. I want to compare completers vs non-completers on a number of variables, e.g. age, sex, employment status, number of medi...
I am currently working on a project where I need to assess the effectiveness of changes made in a production process. Our initial success rate was 50%, and after making some alterations, we've observed varying success rates. I want to accurately determine at what point these changes can be considered statistically sign...
I have a dataset with longitudinal measurements of BMI. The BMI for each participant is measured at 10 different time points. The aim of the study is to investigate how BMI evolves with time. Smoking status is recorded at each time point and is categorised as yes/no. I would like to study the effect of smoking on BMI w...
We have a claimed causal chain $A\to B\to C$. We know that $P(C) < 0.01$ and we know that $P(B|A) > 0.9$ and $P(C|B) > 0.9,$ how can we find $P(A)?$ We might lack information here but can we approximate it?
I am writing my Master's thesis on adult's performance on cognitive and linguistic measures. I have four age groups and am investigating if there is an age difference in the performance on summarized measures and individual tasks. I ran a Kruskal-Wallis one-way ANOVA and found one statistically significant result out o...
Christopher M. Bishop in his book "Pattern Recognition and Machine Learning" nicely explains where does Student t-distribution $St(x|\mu,\lambda,\upsilon)$ originate into. In Chapter 2, it is derived as infinite mixture of Gaussians having the same mean but different precisions ($\lambda=\sigma^{-2}$), which are follow...
I am considering a case where I have a nominal variable with $L$ levels (let us say $L=2$ for simplicity) and a bunch of continuous features. I would like to test if the most centrally located point of each level in the space spanned by the continuous features is surrounded by observations possessing levels which are r...
As far as I am concerned, "multicollinearity" referers to the presence of collinearity between two or more variables, even if there is no pair of variables that have a particularly high correlation. In simple linear regression, we only have one independent variable, but can multicollinearity affect the model in some wa...
I have a dataset with 14 clusters. Each cluster is a time series of 80 periods with autocorrealtion, and I am doing maximum likelihood estimation of a structural multinomial logit model. I suspect there is across-cluster correlation. Therefore, I am thinking two options: Driscoll-kraay standard errors. While I have re...
I want to solve the following: Let $Q=(x, y)$ be a point chosen at random in a unit disc centered in $(0,0)$ and with radius $1$. Calculate the probabilities that $Q$ is within $0.5$ of the center; that $y > \frac{1}{\sqrt{2}}$; that both $||x-y||<1$ and $||x+y||<1$. It seems that this is a problem of geometric probabi...
I read a paper where the random variable $z$ is assumed to follow a log-normal distribution. \begin{equation} \mathbb{E}\left(z^{1-\chi}\right)=\int_{0}^{\infty}z^{1-\chi}\frac{1}{z\sqrt{2\pi s^{2}}}e^{\left(-\frac{\left(\text{ln}z-m\right)^{2}}{2s^{2}}\right)}dz \end{equation} where \begin{equation} m=-\frac{1}{2}\tex...
I am writing a thesis on performances on cognitive and linguistic measures. I have used the Tukey IQR method (Q1-1.5*IQR) to detect lower outliers in a non-normally distributed small sample of various cognitive and linguistic measures. For one measure, data is highly skewed (-3.022) contrary to the other measures. Tuke...
Forgive me, but I'm new to this. I have two columns of categorical data. The data represents access to a particular resource, where a 1 indicates that the individual accessed the resource and a 0 indicates they did not. Each column represents a different sample of the population. I am using a chi-squared test on the co...
I recently studied Rejection Sampling as part of one of my University courses. When justifying why Rejection Sampling makes sense (to "prove", so to speak, that samples drawn using Rejection Sampling actually follow the target PDF, my Professor wrote the following argument. \begin{equation} \text{prob}(x \text{ ACCEPTE...
Consider the binomial sampling model with a Beta prior on $\theta$ and the prior predictive distribution. Let $n$ be the binomial sample size. \begin{align} p(y^{new}) &= \int_{\theta}f(y^{new}|\theta)\pi(\theta)d\theta \\ &= \binom{n}{y^{new}} \frac{\Gamma(\alpha+y^{new}) \Gamma(n - y^{new} + \beta)}{\Gamma(n...
I have a fairly high dimensional dataset that is not mvnormal. I used a copula to model the data and it fits well. How can I go about generating random samples from that copula that are in the original units? I.e., can I transform the uniform margins of the copula back to the original scale? I have an example below fr...
We have done the determination of protein abundance in two fractions (M and P) in one condition (SP). We've done three biological replicas. The data obtained are: \begin{align*} &\text{SP (condition)} &&\text{M (fraction) mean} &&&\text{M standard error} \\ &\text{SP (condition)} &&\text{P (fraction) mean} &&&\text{P s...
I'm looking for a robust way to gradually build up a regression model -- namely I have a linear base-model with a robust set of predictors for which I'm fairly certain I have near optimal weights for, and I want to incrementally add features/predictors without degrading performance. In a sense, I'm trying to devise a g...
This is my sampling algorithm Let p(x) be a discrete distribution and f(x) be some function on real numbers. Consider $\textbf{Generate Samples from } p(x): \text{Initially, you sample } x_1, x_2, \ldots, x_n \text{ from the probability distribution } p(x).$ $ \text{Sample } x_i \text{ from } p(x), \text{ for } i = 1,...
Alice and Bob work at the same place for 30 minutes and 45 minutes respectively. They are free to choose a starting time anytime between 8:00am and 9:00am. What is the probability that they will see each other during their shifts? I'm not sure if I approach this question correctly. I would answer this question as follo...
If $\mathbf{X} \sim_{iid} \mathcal{N}(\mu, 1)$ then we know that the sample mean $\bar{X} \sim \mathcal{N}(\mu, 1/n)$, how would we show that $$\mathbf{E}\left(\frac{1}{\bar{X}}\right) = \infty $$ and more generally for any normal random variable $X$ how would we show $\mathbb{E}\left(\frac{1}{X}\right) = \infty$, I am...
I'm reading Tensor Methods in Statistics by McCullagh 1987, (P209 for this question) and I can't understand one step he uses. He begins with the usual log-likelihood \begin{equation*} l(\theta; Y) = \sum_i l(\theta;Y_i). \end{equation*} And then writes "It is convenient in the calculations that follow to make the de...
I want to solve the following A salesman has two different stores where he sells computers. The probability that he sells, in one day, a computer in the first store is $0.4$ and independently, the probability that he sells, in one day, a computer in the second store is $0.7$. Additionally, suppose that it is equally pr...
I'm currently exploring Meta's positional interpolation method, which aims to increase the context size in their large language model. This method extends the context length from n x n into n′ x n′. It achieves this by interpolating new token values in between existing ones. My question: Does this interpolation techniq...
I was planning on running a statistical test for hypothesis testing, but was confused if statistical power is important once a test is run. Looking at this confusion matrix, one would ideally set alpha to be a small number and beta to be close to 1 to avoid the errors. Test power (1-B) has been suggested in other on...
Consider a random variable $X$ with mass function $p_{X}(x)$ given by: $$P(X=k) =\frac{6k^2}{n(n+1)(2n+1)}, \quad k= 1, \dots, n$$ I want determine the cumulative distribution function of $X$ We know that $$F_{X}(k)=P(X \leq k)= P\left(\bigcup_{k' \leq k} \{X=k' \} \right)=\sum_{k' \leq k} p_{X}(k')$$ In our case this ...
I have run separate EFAs and then CFAs on the second half of the dataset to confirm the solution and the one-factor solution fits well across time points. One weird thing is happening though when I assess configural measurement invariance across time, the loadings for a few of the time points are inverted, so instead o...
I'm looking for a way to make a scatterplot of the correlation between two questionnaires using Cronbach's alpha: Data: measurements <- matrix(c(2, 1, 2, 1, 0, 1, 1, 1, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
I am struggling with interpreting model results from a brm() model. The first result uses scaled and centered data with command scale(df$column, scale = TRUE, center = TRUE). > summary(global.use.initial) Family: bernoulli Links: mu = logit Formula: use ~ 1 + iogs_std + ipred_std + idepth_std + idry_std + iopenwat...
Why do we need a consistency assumption in causal inference? I think the consistency assumption is quite obvious and it is more like a definition for the observed outcome.
I have got a timeseries data with which I plotted a frequency spectrum and I could eyeball all the significant peaks (significant frequencies) in the plot. But I want to do this for a spatial data (pixelwise). So, is there any statistical test with which I can test, if the particular frequency is significant or not. if...
If the variance of data set A is 4, and the variance of data set B is 2, can we say that the data in set B is twice as dispersed as the data in set A? If the standard deviation of data set A is twice that of data set B, can it be understood that the dispersion of data set A is twice that of data set B?Why is there a ne...
I was trying to familiarize myself with state estimation theory by going through Optimal State Estimation and I realized I don't have the required background in Multiple Random Variables and Multivariate Stats. But all books on these topics I can find seem to be geared towards experiment design or economics or biology....
I have the following model: LOS (length of stay) = b0 + b1 Age + b2 Gender + b3 BMI where Age and Gender are control variables, and my main IV is BMI. And this model isn't made for predictive purpose; we want to know if high BMI causes more LOS. Results showed insignificant effect of BMI (P > .05). I then tried to crea...
When doing feature selections, I've noticed that sometimes the same model converges faster with feature set A, than with feature set B, in the very beginning, but ends up with a worse loss later. Here's a concrete example: The model is a tree model and trained with lightgbm as a regression task, minimizing RMSE. Featu...
I have a question regarding how to analyze categorical data in this situation. Assume that I have five choices of food for people to choose from and I expect that 50% of my research participants will choose the first choice, while the other 50% will choose the second choice. However, in reality 20% of the participants ...
I'm trying to understand how to set s for the seasonal order in the context of statsmodels.tsa.statespace.sarimax.SARIMAX. Per the documentation: s is an integer giving the periodicity (number of periods in season), often it is 4 for quarterly data or 12 for monthly data. Default is no seasonal effect. I believe this...
I would like to better understand the differences between the results obtained with the SARIMAX function and the auto_arima function. In particular, I would like to understand. why the two models show different results despite having the same order, using the same method and the same number of iterations. (I had found...
I am trying to model a series (mainly as self-education, as a way of deepening my time series knowledge). The series is percentage growth in GDP per capita for the United States, taken from the World Bank World Development Indicators databank. I would like some advice on deciding what kind of series is represented in t...
I am running a knot-like type of regression and have a couple of questions: Imagine that we are working with daily data that spans over $3$ years. Consider the following model: $y_t = \beta_{0, t} + x_{1, t}^{\beta_{1, t}}$ Where as $\beta_{1, t}$ is modelled as follows: Imagine that we place three knots, one at the st...
I'm trying to understand if the max statistic method for permutation test is appropriate to use and how i should apply it in my situation: I have a sample of 38 individuals who performed a task and we administered two questionnaires to them: the nasa-tlx, which has 6 subdomains, and a questionnaire we wrote on usabilit...
From the original SHAP paper paper we understand that the Shapley value for a linear model take the form: $\varphi_i = \beta_i(x_j - \mathbb E[X_j])$ It's easy to check that this formulation satisfies all the usual Shapley Value properties. However if we want to have a global explanation something weird happen. Let's s...
I am trying to figure out how the computer in this game works. In short: it's like normal monopoly, except instead of owning a property comletely everybody can buy shares for the property (max 9 available). If a player lands on this property and you own some shares you also profit from the paid rent. Or, for example, i...
In order to estimate the proportion of fradulent invoices, we did a two-stage probability weighted sample. A subset $m$ out of $M$ departments were chosen in the first stage, and $n_m$ invoices were then chosen in each department, so the total sample size is $n=\sum n_m$. First- and second order inclusion probabilities...
why are y_hat and ε independent? I think ε dose effect y_hat
I am trying to find similar movies in a dataset where each movie has zero to five genres. (I also have more dimensions but those are not relevant to the question.) For this I'm trying to use nearest neighbors. The data is transformed into a matrix of approximately 100 columns using either MultiLabelClassifier or TF-IDF...
I use SAS to fit a simple mixed model where there is nested random effects of Block within Location like this: proc mixed data = SAS_R_1; class Location Block Trt; model Adj = Location Trt Location*Trt; random Block(Location); run; There is a lot of output but I focus mostly on the random effects covariance esti...
Suppose I have samples drawn from a random variable, and I want to multiply that random variable with a scalar constant. How should I transform the samples such that they would have been drawn from that scaled random variable? For a normally distributed variable, I can just do: def transform_normal_samples(samples, mul...
Is it possible to do multiclass classification using GPBoost? For example when we have 3 or more classes (e.g. specie A/ specie B/ specie C) from a clustered data set (e.g. several measurements over the same subject or clustered by region/city/state). I understand that in GPBoost we can set likelihood="binary", but doe...
I want to perform a multiple regression, comparing a model with "traditional" risk factors, with a model that has two tested "novel" risk factors. I'm want to make sure that the analysis is properly powered for my achieved sample size. I am using G-Power for sample size/power calculations. There are two options for lin...