instruction
stringlengths
9
38.7k
In Google's paper YouTube-8M: A Large-Scale Video Classification Benchmark in section 4.1.2 Deep Bag of Frame (DBoF) Pooling second paragraph, the first sentence says: The obtained sparse codes are fed into a pooling layer that aggregates the codes of the k frames into a single fixed-length video representation. W...
I'm fairly new to econometrics and I'm trying to understand the simultaneity bias in my investigation: I'm investigating to what extent salary influences performance in Major League Baseball using panel data of individual players and a fixed effects estimator. Salary and performance are determined simultaneously: (1) P...
I would like to know how to prove that: $$ E(X|X>a) \geq E(X) \ \ \forall a $$ I know there is a question related with $ a = 0 $ but this question is more general. Assuming $ X $ is a Real unidimensional R.V. I know is almost obvious but I would like an algebraic proof, manipulating the expectation formulas: $$ E(X)...
I am trying to use this equation to calculate the alpha (forward) probabilities for the EM/Baum-welch algorithm but I'm running into some confusion. I don't understand what the $h_t$ is. I know its a hidden state, I have 16 different hidden states but don't know which one is $h_1$ for instance. Can I arbitrarily assig...
I have conducted meta-analyses for a Cochrane systematic review. I was comfortable pre-specifying and justifying whether a fixed effect or random effects approach will be used in the MA. Having completed the meta-analyses and used random effects models in some instances my co-author is requesting that I include results...
I am little confused regarding the concept of MEAN SQUARED ERROR : my text book says that mean squared error of an estimator say T for estimating the parameter ,say $\theta$ is given by : $ \ $ MSE = $E(T-\theta)^2$ ...... 1 , and then they say that estimators with minimum MSE rarely exists in general ,therefore we r...
Need to understand the working of 'Embedding' layer in Keras library. I execute the following code in Python import numpy as np from keras.models import Sequential from keras.layers import Embedding model = Sequential() model.add(Embedding(5, 2, input_length=5)) input_array = np.random.randint(5, size=(1, 5)) model...
currently I just met a case and Give the context below: I got a 1000 (rows) x 6 (columns) data set. The variables are Date, Hour, average temperature, average humidity, the sum of water consumed in one hour, average ph value in the water. How should I build a model to predict the daily water consumption in the next few...
I have 25 correlated independent variables and one dependent variable that is an aggregated score of a Likert scale. I also have 90 samples. I want to do variable selection for linear regression so I am using LASSO. In python I used LASSO CV (coordinate descent). Q1 I can use LASSO AIC/BIC, LASSO CV, LASSO LARS CV is t...
In Clinton, et al. 2010, the authors use splines to interpolate 100 equally spaced data points per year from only about a dozen actual measurements. The 12 (or possibly less for the NDVI data) annual obser- vations of precipitation and NDVI were not enough for the computation of the various metrics. This is due ...
I am conducting an event study in STATA based on this description: http://dss.princeton.edu/online_help/stats_packages/stata/eventstudy.html I reached the point when I need to calculate t-statistics to be able to test whether cumulative abnormal return for event window is statistically significant from 0. And now follo...
If a GLM fit is applied to the dataset it was fit to, should the means of the predictions and the data be the same? I assume in a penalised GLM (e.g. using glmnet in R) this is't the case, but is it true for the general case? What problems would I cause if I scaled the factors (or just the intercept if I'm fitting to t...
I am planning on doing a variance components analysis (random effects anova). I'm wondering if anyone has any advice regarding balancing the number of levels to include in the design vs. the type of design. For example, I could do a $2^3$ full factorial design, but if I want to include more levels, I would have to swit...
Is there a way that, given a sample set of random values, using machine learning techniques one can be able to predict its probability distribution. What I mean is that, if I generate different sample sets, each drawn from different distributions, i.e. weibull, gamma, exp or lognormal, I can use these sets as training...
I have a set of variables, say different Jeep models like Compass, Wrangler, Cherokee ...., and for each a respondent does a rating from Very Satisfied - Very Unsatisfied (Ordinal from 1 to 6) and I want to do a test of sig between the mean rating for each model. To further clarify, the models are variables in an SPSS...
I am asking for your help. I have 3 variables that are divided into 4 groups (Quantitative variables). I intend to check if there is any difference between the groups for each variable. My difficulty in using ANOVA - it indicates that one of the group is different but it does not indicate which one of the group is diff...
I'm working on the problem of migrating voting data from one grouping, electoral divisions, to another, census divisions. I'm not sure if this is a common problem in statistics broadly, but in the spatial world it's often called the "modifiable areal unit problem", and I'm struggling to find a way to quantify the error...
My data is composed of 301 observations from 34 subjects, each subject can have one or more observations (up to 15). Each observation belong to one of three categories. Two of the categories differ only slightly. Think of the three categories as an attribute. E.g. type of vehicle: CAT1 = four wheels car CAT2 = four w...
I am training 3 different models, with varying parameters like learning_rate, regularization_strength. But number of epochs is same for all. For a fixed no. of epoch, model 2 has the highest validation loss value. But the accuracy of it is highest in test set. How can it be possible ? Or I have some bug ?
I'm working on a linear regression problem where I have variables that improve the response, but have very low variance. In these variables almost all of the terms are zero, but the non-zero terms are positively correlated with the response. However, when I regress it I get a negative coefficient. Most of the informati...
I've been asked by a reviewer to provide statistical results on an algorithm's performance. My algorithm is stochastic, so 50 runs will give 50 slightly different results and I compare with deterministic algorithms that give the same result each time. Originally I thought that by simply showing a higher mean and median...
The following likelihood function can be found in reservoir simulation literature: $$P(F|k) \propto \exp\left(-\frac{||F-F_k||^2}{\sigma_f^2}\right)$$ Where: $k$ = model $F$ = data $F_k$ = simulation of data $\sigma_f$ = precision of data $F$ I am used to likelihood functions that are equal to the pdf of the model (e....
I did a Logistic Regression (LR) on a 2-class problem (77.3% negative, 22.7% positive), and the results are as follow: $\text{logit} (p) = -2.0 + 1.4X_1 + 1.3X_2 + 0.2X_3 - 0.3X_4 - 0.7X_5$ The final model Likelihood Ratio Tests indicated the model is significantly better than the intercept-only model (Chi-square = 21....
I am going to do an experiment with English and Dutch sentences. The same participants read both the English and the Dutch sentences. There are two options participants can choose after they've read the sentence, option A and B (both options represent a certain interpretation of the sentence). So there are four possib...
In classical statistics literature, finding correlation between variables is important and we also have hypothesis testing on if correlation is 0 (example on this link) I feel I need something opposite because my data is different. Unlike most "cleaned" data sets in statistics, my data is coming form many "sensors". Th...
So i've done a survey with a 5 point likert scale (strongly disagree, disagree etc) for 50 questions relating to five major personality scores. I am assessing these against drug use (alcohol, cannabis and cocaine use). My hypotheses are that alcohol users will score highest in one of these five scores and lowest in ano...
What kind of probability distribution features one can make use of in order to identify a specific pdf? I was thinking of using the moments of the distribution (mean,var,skewness and kurtosis) but I am not sure whether specific moments (or combination of them) identify specific pdf. Edited : The problem is the followi...
can u guys give some hint on how to prove that tilde beta is a linear estimator and that it is unbiased? $$\tilde\beta=\frac1n\sum_{i=1}^n\frac{y_i-\bar{y}}{x_i-\bar{x}}$$ i have attempted to transform the mean of y part to express it in terms of yi by separating yi and y bar, so that it can be expressed in the summati...
I'm thinking about writing my bachelor thesis on how "internet users" (per 100 people) affect gdp per capita for developing countries. I´m thinking of using a regression analysis. But how can I identify the effect of only "internet users" when the gdp has a positive time trend. I will use data from 1995-2015. Helps wou...
So, I've read some posts on covariance in this site and I think I have finally managed to get my head around the concept. However, there is still one thing about it that I really wish I had more intuition on, namely, when calculating the covariance between two random variables $X$ and $Y$, why do we average the product...
I would like to know what is the best way for determining the relationship between 2 (or more) variables: one (or more) independent that is (are) set on the measuring device, and a dependent variable that is the output measurement which has some fluctuation. I am aware that the question is rather basic and silly: what ...
I'm experimenting with replacement for normal distribution for my models. So far, I tried Gamma and Inverse Gamma distributions. Gamma significantly underestimates the probability of the extreme events, while Inverse Gamma overestimates it by several orders of magnitude. I'm probably looking for something in-between. W...
There is a lot of literature written on the subject of choosing the correct number of classes for a latent class model (I mean "latent class model" in a very, very general sense, which encompasses a lot of different types of models, such as finite mixture models, Hidden Markov Models, Bayesian latent class models, etc....
Could someone give me advice on the architecture of NN for the following task: I have a list of agents (with some properties) and a list of activities in time of each agent (an every agent has a different number of records of the activities). I need to divide agents on two classes. I have big amount of labeled data. Th...
I am conducting an analysis in which I have an interaction between a categorical and continuous predictor on a continuous outcome variable. My question is how I should present these results to a reader with the caveat that it makes (conceptual) sense for the continuous variable to be the moderator, which precludes a co...
Background: The "4SID" method allows one to back analytic models from data using a form similar to that of a Kalman filter. (1) The 4DVAR is an approach to use data with an analytic model for weather forecasting that is also an extension of the Kalman filter. (2) The ensemble Kalman filter (EnKF) is also used to combin...
I am learning hypothesis testing for Pearson Correlation Coefficient. The source did not explain why the test statistic $$\frac {r\sqrt{n-2}}{\sqrt{1-r^2}}$$ satisfy T distribution with $n-2$ degree of freedom. Could anyone show me the assumption and proof?
When I normalize a data set and compute the cosine similarity between the rows, the cosine similarity differs from the one without any normalization. Say there are 4 2D vectors: (1, 1), (2, 2), (1, 2) and (2, 1) Before normalization: cosineSimilarity between (1,1) and (2,2) is 1.0 After normalization these vectors beco...
I have data in which respondents chose 1 of 3 options. I would like to test whether one of the responses was chosen significantly more frequently than the other two. If there were only two options I could use a one sample binomial test to see if it was chosen more than the constant of 50%, but I am not sure what the ap...
In DeepMind's paper on Deep Q-Learning for Atari video games (here), they use an epsilon-greedy method for exploration during training. This means that when an action is selected in training, it is either chosen as the action with the highest q-value, or a random action. Choosing between these two is random and based o...
I had a discussion with my colleague about Kfold and StratifiedKfold validation in scikit learn. My understanding of these two ways of validation is that at the beginning of the validation process, the data set is randomly divided in k-folds. k-1 of those folds end up in the train dataset. 1 of those folds ends up in t...
I have many users, each of whom may or may not have had the opportunity to perform each of various actions and may or may not have performed it. That is, for each action, some users had the opportunity to perform it and some did not; among those who had that opportunity, some did so and some opted not to. Moreover, tho...
Do you remove the seasonal component, the trend component, or both, when adjusting a time series to avoid finding spurious correlations? I have two time series x and y with trends and yearly seasonality and I would like to test for correlation. I read this article about spurious correlation in time series https://svds....
I have some idea that I would like to test and I think the ML would be great solution. But I'm a little bit lost how it could be implemented. The input is just a text, could be anything (but providing some information), for example "Cat has fur". The output is an object. If it's presented in Json, could be for exampl...
I'm working on a project to forecast sales / # of products for each city for 12 months into the future. The issue is that historical data looks wildly different for each city; however, sales data and product data independently follows observable trends. Would it be better off to forecast the ratio itself or instead fo...
Having studied ordinary fully connected ANNs, I am starting to study convnets. I am struggling to understand how hidden layers connect. I do understand how the input matrix forward feeds a smaller field of values to the feature maps in the first hidden layer, by moving the local receptive field along one each time and ...
I recently performed a meta-analysis where I was basically looking to find the proportion of people with disease X in people with disease Y. I did not find a significant value, it was solely the proportion (also significant heterogeneity was found). I am wondering, how would I discuss these results in the discussion se...
I have plotted some experimental data of mine, and these data points fall into the following distributions: So, these are fairly non-trivial looking distributions. I would like to figure out methods to quantify how these distributions differ. Perhaps a Kullback-Leibler divergence? What other methods could I use to d...
I know that VAR should be employed only with stationary series. Is the same condition required for analysing impulse response? That is, should the impulse response be analysed on stationary variables only? Because normally a VAR is estimated using stationary variables and after that impulse response can be analysed. B...
I'm using several clustering algorithms from sklearn to cluster some data, and can't seem to figure out what's happening with DBSCAN. My data is a document-term matrix from TfidfVectorizer, with a few hundred preprocessed documents. Code: tfv = TfidfVectorizer(stop_words=STOP_WORDS, tokenizer=StemTokenizer()) data = t...
In my event study I use an OLS time-series regression. $y_t$ is the dependent variable on day $t$. $x_t$ is the explanatory variable on day $t$. This regression uses observations during the so-called estimation period which precedes the event window: (1) $y_t=\alpha + \beta x_t + u_t$ (or in matrix notation $y=Xb+u$) ...
According to this very interesting article in Quanta Magazine: "A Long-Sought Proof, Found and Almost Lost", -- it has been proved that given a vector $\mathbf{x}=(x_1,\dots,x_n)$ having a multivariate Gaussian distribution, and given intervals $I_1,\dots,I_n $ centered around the means of the corresponding components ...
I'm pretty new to machine learning and I have a question regarding weighting features. I was able to get code running with scikit-learn and random forest. Now I would like to weight certain features higher to give them more importance. The data ranges anywhere from T/F to dollar amounts. Can someone point me in a good ...
I've come across an error metric used to quantify a model's reconstruction error: $$ \varepsilon = \frac{\sum_i{\left(y_i-m_i\right)^2}}{\sum_i{\left(y_i-\bar{y}\right)^2}} $$ where $y_i$ is the $i$th data point, $m_i$ is the model's estimate of the $i$th data point, and $\bar{y}$ is the mean of all data points. The n...
How does one combine imputation of a value with an observation of that value? A consequent question: When the values that would be imputed (if they were missing) differ greatly from the observed values, is there a procedure for quantitatively/probabilistically assigning error/blame to the data sources? To further elabo...
In my project I want to create a logistic regression model for predicting binary classification (1 or 0). I have 15 variables, 2 of which are categorical, while the rest are a mixture of continuous and discrete variables. In order to fit a logistic regression model I have been advised to check for linear separability ...
Has anyone heard of a Wilks' trinomial significance test before? I'm trying to decipher an old approach with little documentation that was used in a product preference study (i.e., prefer product A, prefer product B, No preference) that employed a PBIB (partially balanced incomplete block) design. The main thing I'm h...
I want to come up with a time series model that will enable me to forecast the number of life insurance claims. I have collected the data (number of claims) from January 2013 to December 2016. My question is what model can best suit my data and how best can I set up the model. The plot is as below
first post here! I have a project to estimate commercial real estate properties given categorical and continuous variables. I have ran a step-wise linear regression model to pick out a good formula in RStudio. (Adj. Rsq = .90 also, I know I need to do PCA and some type of categorical ANOVA test still, but I just want ...
$$ w = (X^T X + \lambda I_n)^{-1} X^T y \rightarrow \sum^m_{i=1} \alpha_i x_i \\ \alpha = (\alpha_1, ..., \alpha_m)^T \rightarrow (XX^T + \lambda I_m)^{-1} y $$ From what I understand, the above demonstrates the conversion from primal to dual form. However, I am at a loss as to the definition and meaning of each of t...
I did an experiment and obtained the following values which I want to correlate to see if there is a connection between sampling method A and method B. A,BPair 1: 4000,3500Pair 2: 1500,40000Pair 3: 5000,4500Pair 4: 2500,7000Pair 5: 1000,1000Pair 6: 12000,17000Pair 7: 2000,2000Pair 8: 4000,40000Pair 9: 13000,25000Pair 1...
How to use $\chi^2$ test to test if my data follow a $\chi^2$ distribution with a fixed degrees of freedom? or is there any way to do it with Matlab?
I am looking to collect data for a multilevel CFA (two levels). I am unclear how to determine the number of clusters needed for identification. I know that the number of parameters is k(k+1)/2 multiplied by 2 (within and between portion of the model) plus k for the indicator means. With k = 35 (number of indicators), t...
I'm trying to make predictions based on customer service samples using randomForest and GBM, I'm leveraging on 2 stage modeling, i.e. 1st stage to predict whether customer will react or not, 2nd stage will predict how much they will spend. My 2nd stage model is training on those who spend>0 following is the prediction...
I know that if If $X$ follows a $\chi^{2}_{k}$, then $cX$ $(c>0)$ follows a $\Gamma(k/2,2c)$, what about when $c<0$?
This is a qualitative question. In the literature of particle filters/ sequential monte carlo, particle degeneracy is unavoidable. However, frequented cases where it may happen is when the likelihood is very peaked. The result of this $$\tilde{w}^i_t=\frac{p(y_t|x_t)p(x_t|x^i_{t-1})}{q(x_t|x^i_{1:t-1},y_t)}w^{i}_{t-1}...
I have found a number of posts about how worried one should be when they get convergence warnings from lme4 (such as: How scared should we be about convergence warnings in lme4). However, I have not been able to find equivalent postings about convergence warnings when using multiple imputation datasets, specifically if...
My data takes the following form: Outcome variable = no of suicides (count data) Explanatory variables = Age (grouped into young, middle and old), Gender, Country, Year I am running a Poisson regression. I have been told that I need to take the population size of each country into account, in order to be able to compar...
in the textbook "Introductory to Econometrics" Wooldridge writes $\hat{\beta}_1=\hat{p}_{xy}\cdot(\frac{\hat{\sigma}_x}{\hat{\sigma}_y})$ where $\hat{\beta}_1$ is the OLS-Estimator, $\hat{p}_{xy}$ is the correlation between $x$ and $y$, and $\hat{\sigma}_x$ is the standard deviation of $x$. When I derive this formula ...
I have found a few decent ones about specific resampling applications such as bootstrapped confidence intervals, but nothing broader. A journal article or book chapter would be preferable to an entire book, but all recommendations are welcome. Edit: I am looking for an article or chapter that provides an overview of t...
I'm comparing different machine learning for classifying sensor data and I need their complexity to select the most efficient. Which are the Big-O notation for the following algorithms (I add what I found): SVM (linear and all vs rest)- O(n^3) Random Forest (CART) - O (M(mn logn)) M-number of trees m-number of attribu...
I am in a situation where sampling proportional to some weight might be very beneficial. In order to estimate $\tau$ the population total / sum I use the Hansen Hurwitz estimator. That is, $$\hat{\tau}_p = \frac{1}{n}\sum_{i=1}^n\frac{y_i}{p_i}$$ with variance $$\hat{Var}(\hat{\tau}_p) = \frac{\frac{1}{n}\sum_{i=1}^n(\...
I found this article, describing a systematic approach to stratified analysis: https://www.linkedin.com/pulse/conducting-stratified-analysis-test-confounding-navneet-dhand Test crude association of the explanatory variable with the outcome or response variable, i.e. conduct a chi-square test to evaluate significance ...
I've looked through a related question and another on this topic but it seems I'm still missing something. I understand that in a multiple regression from these questions and answers that a given parameter is estimated while other variables are held at their mean. If I had a variable Y that was predicted by a series of...
I have a dataset consisting of the following: one column language containing five different languages. Two other columns Canonicity and Intrinsic containing either (0, 1). One last column, useOfIntrinsic. You can view the data here. I would like to test the use of intrinsic as a function of Language, Canonicity and use...
I'm using the Generalized likelihood ratio test in order to get the t test for slope, i.e., $H_{0}:\beta_{1}=b_{1}$ vs $H_{1}:\beta_{1}\neq b_{1}$ If $b_{1}=0$, we have that ${\sigma}_{MV|H_{0}}^{2}=\sum{{(Y-\overline{Y})}^{2}}$ and using the Generalized likelihood ratio test, we can use sum of squares and these fact...
I did a simple experiment with trees: 5 species (sp) and two management (trt). I assessed the diameter (diam) through the time (month=1:24) and I'm interesting in the factors interaction effect, I mean if the management is suitable for some species. The dataset has some limitations since it is not balanced, so in 2 out...
Why does ridge regression in glmnet and sklearn give very different results? library(glmnet) X = matrix(c(1, 1, 2, 3, 4, 2, 6, 5, 2, 5, 5, 3), byrow = TRUE, ncol = 3) y = c(1, 0, 0, 1) reg = glmnet(X, y, alpha = 0, lambda = 1) coef(reg) glmnet output: 0.18811436, –0.02910451, –0.04614124, 0.26402541 import numpy as np...
I am trying to understand how multi-label classification is done and rather got confused with what wikipedia has to say, I am directly quoting it: "Several problem transformation methods exist for multi-label classification; the baseline approach, called the binary relevance method,[1][2][3] amounts ...
When using neural network for classification problem, and using softmax as last layer for last layer. Typically, we have a prediction and a confidence level. However, is there such confidence interval measure for neural network regression problem?
Is there a big difference between general linear model and generalized linear model? I am quite confused a bit with the two.
When we have an estimate of the variance $s^2$ obtained from $n$ observations, $x_1, x_2, \dots, x_n$, we can calculate a 95% confidence interval of the true variance $$\left( \frac{(n-1)s^2}{\chi^2_{\alpha/2}}, \frac{(n-1)s^2}{\chi^2_{1-\alpha/2}} \right)$$ I want to get narrower confidence interval. The best thing to...
This question is based on my doubt on the application of Lloyd's algorithm in minimizing quantization error when performing scalar quantization to this problem. I have a quantization function to partition /quantize a real valued data. The way I understand the working of Lloyd's algorithm is that it can be used to opti...
I have a line plot and occasionally there are NaNs that appear in the Y-axis. If I put them as zero then people will confuse that for actual zeros. If I remove them from the dataset, the visualizations look bad because there isn't enough data (there might only be 3-4 data points at a given time). How can I effectively ...
I would like to ask if there's any existed works about hypothesis testing with faulty data. The specific question is as follows: In normal hypothesis testing, say I have n i.i.d. datas $X_1,X_2,...,X_n$ with distribution $P_0$ under $H_0$, and $P_1$ under $H_1$. Now a fraction $b$ of the datas are compromised, so the...
I'm developing a customer satisfaction survey for a course in yoga. We have very few participants below the legal age of 18. People retire at year 65 in my country. I don't ask directly for a specific age or birth year, because from our past surveys, quite many people don't want to answer if the age question (or any ot...
I am exploring churn and lifetime modeling. From what I see on various online material, the lifetime period is defined as 1 / churn-risk. For example, if the churn risk for a 12-month period is estimated to be .3, the lifetime is calculated to 3.3 years by 1 / .3. Is there a mathematical proof of this way of modeling...
I want to estimate a panel equation of the form $$ y_{it}=ρ y_{i,t−1}+β_1 x_{1,t}+⋯+β_k x_{k,t}+ c_i+γ_t+ϵ_{it} $$ where $c_i$ are country specific effects, $γ_t$ period effects and $ϵ_{it}$ error term. the problem is that some of individual time series have certain trend, but the first difference of the variables are...
I have a matrix, $X'X$, which is singular meaning that I cannot invert it. I need the inverse of this matrix to perform two independent things. I need it for the design of experiments, in R using optFederov() algorithm. Also I need it invertible for OLS. I believe the two possible sources of singularity are: 1.- Many ...
I am using h2o Generalized Low Rank Models for tuning a binary PCA (Logistic loss + Quadratic regularization) to perform a recommender system task. I am using the H2O infrastructure using the GLRM approach. Below the code where a model is run. bestGlrm<-h2o.glrm(training_frame = train.h2o.wmiss, cols = glrm_cols, k = b...
I am wondering if there are classical (or not so classical) examples of negative autocorrelation in a regression model. To expalin the context : I am explaining OLS limitations, heterosckedasticity and autocorrelation for the moment, and I want to showcase as many examples as possible, but I have only encountered posi...
I encountered a mixed-design experiment that consisted of two independent groups and three repeated conditions. The authors conducted an analysis of variance followed by post-hoc paired-samples t-tests. Three paired-samples t-tests were computed to compare the conditions within each group (i.e. six tests in total). In ...
In my prediction model, there are 20 independent variables, and the dependent variable [y] has a range of 0-4. In the first approach I use LASSO to make a prediction [I have separate training and test sets]. Here is the result of the model evaluation: METHOD MAE R2 RMSE LASSO 0.561 0.141 0.985 In t...
suppose $X_1,X_2,...,X_n$ be a random sample of distribution with Probability density function $f_\theta(x)= \displaystyle \frac{2x}{\theta^2}e^{\displaystyle\frac{-x^2}{\theta^2}}, x>0, \theta>0$. under loss function $L(\delta, \theta)= (\displaystyle\frac{\delta}{\theta}-1)^2$how can I calculate minimax estimator f...
I am trying to figure out how Eq. 45 simplifies to Eq. 46 in the paper - "Gibbs Sampling for the Uninitiated" by Resnik and Hardisty.www.cs.umd.edu/~hardisty/papers/gsfu.pdf (page 15) Eq. 45 $$ \frac{\Gamma{(N + \gamma_{\pi1} + \gamma_{\pi0})} \Gamma{(C_x + \gamma_{\pi x} -1)}}{\Gamma{(C_x + \gamma_{\pi x}) \Gamma{(N +...
I have a data set which is 3 columns and about 50,000 rows. I am trying to do some cluster analysis and would like to speed it up. Most examples online use data sets like iris which are relatively tiny. Take the following code: nb <- NbClust(d, distance = "euclidean", min.nc = 2, max.nc = 30, method = "complete", inde...
I am studying multivariate statistics and I don't understand the meaning of Jacobian of the transformation for pdf of function of random vectors. If I have a random vector, let's say bivariate, (X,Y) with joint density f(X,Y) I know how to find the joint pdf of (U,V) with U = g(X,Y) and V = h(X,Y) I did a lot of exer...
I have recently noticed that the var() function in R returns a different value from the analogous function in the python package numpy. In particular, R's var() function seems to be actually computing what is sometimes called the quasi-variance: $\text{qVar} = \frac{1}{n-1} \sum_{i=1}^{n} (x_i-\bar x)^2$ Instead of t...
I have two data sets both matrices of latitudes and longitudes. $A = [(X,Y),(X_2,Y_2)]$ $B = [(X_3,Y_3),(X_4,Y_4),(X_5,Y_5)]$ They are of different sizes I want to calculate by how much each of the pairs of (x,y) coordinates in A correlate with all of those in B. So then can order A by those that correlate most clos...
I am reading the follow webpage: http://www.randomservices.org/random/dist/Convergence.html I can understand b. and c., but I don't understand how they get $f_n(x)=\left\{\begin{matrix} 1& x=\frac{1}{n}\\ 0& x \neq\frac{1}{n} \end{matrix}\right.$ I think $f_n(x)$ should always be $0$, because: Since we know that $...