1
vote
1answer
6 views

Algoithm to find subsets with high correlation

I have a reasonably large dataset (d) with predictor variables x1...xn and a target variable y. I can use recursive partitioning (such as CART or rpart in R) to find subsets of d with a high (or low) ...
1
vote
1answer
45 views

What does correlated data mean and how can I visualize it with scatterplot?

I'm playing around with the Abalone dataset in R and following along with this article. The dataset has 8 variables that are taken into account to predict the number of ...
1
vote
1answer
21 views

Using Mantel to explore relationship between geographic distance and a multivariate character

I'm working with bird songs. A song is composed of many vocal parameters [highest frequency (Hz), lower frequency(Hz), bandwidth(Hz), duration (s), number of notes, and son on....] I'm interested in ...
1
vote
1answer
22 views

Is it possible to measure the independent variable with part of the dependent variable

I have Beta as my independent variable and Economic value added (EVA) as my dependent variable. To calculate EVA I need to use Cost of capital and to calculate that I have to use Beta, so is it ...
0
votes
0answers
10 views

Detecting pattern in panel Data R

I am struggling on panel data in R. I detected some serial correlation within my data, and now I would like to detect some pattern within it. There are 166 observations and 34 variables and the data ...
1
vote
1answer
31 views

Treating multiple observations per object

I am working on a project whose aim is to analyze the relationship between machine elements and their price. My data consists of thousands of machine elements, their price, as well as technical and ...
0
votes
0answers
16 views

Statistical test to measure correlation between inter-rater mistakes

I'm working on a project that involves collecting crowd-sourced labels for discussion forum posts. The task given to annotators was to look at a forum post and to decide which of six classes the post ...
0
votes
0answers
38 views

How to get correlation between two categorical variable and a categorical variable and continuous variable?

I am building a regression model and I need to calculate the below to check for correlations Correlation between 2 Multi level categorical variables or 2 binary variables Correlation between a Multi ...
0
votes
0answers
58 views

How to develop a prediction model based on correlation in R?

I have two sets of data, say sales and profit, and I have calculated the correlation between these two data over different months using R. So currently I have ...
0
votes
0answers
19 views

Strange: Partial Correlation changed correlations values to be negative?

I am trying to investigate the correlation values. A big problem happens. The method I used is in corpcor package in R. I have a column as missing data. I firstly calculate the correlation matrix. ...
1
vote
0answers
23 views

How to specify binomial glmm with random and correlation in R?

I am working on developing a model with a binomial response variable. My data consist of GPS points from tracked animals. The data set is large and contains 15,000 observations from 40 individuals. I ...
2
votes
1answer
41 views

Exact central confidence interval for a correlation

I am working my way through (T.J. Diccio & B. Efron, "Bootstrap Confidence Intervals", Statistical Science, 1996, 11(3), 189–228), and I'm stuck even before I get to the good stuff. In the ...
1
vote
1answer
50 views

Correlation coefficient for data table

I would like to display correlation coefficients in a table (ideally - with p-value). However, my code produces exactly the same values for each period (so something is obviously wrong). Could you ...
2
votes
1answer
15 views

Small number of points driving correlation

I am currently looking at trying to find high correlations in a series of data. I initially just thought I could check the correlation of the data and choose those with the highest correlation but ...
2
votes
1answer
59 views

Value of r, i.e. correlation coefficient, of data points on a horizontal straight line

1) If we use the formula $$r = \displaystyle \frac{\displaystyle\sum_{i=1}^n \left( x_i - \bar{x} \right) \left( y_i - \bar{y} \right)}{\sqrt{\displaystyle \sum_{i=1}^n \left( x_i - \bar{x}\right)^2 ...
1
vote
3answers
107 views

Correlations with categorical variables

I have a dataframe with many observations and many variables. Some of them are categorical (unordered) and the others are numerical. I'm looking for associations between these variables. I've been ...
2
votes
1answer
61 views

Interpret Pearsons correlation output from R

I have conducted Pearson's correlation in R and need help interpreting the results. ...
0
votes
0answers
37 views

Correlation tests – multivariate correlation matrix?

I just got comments from a reviewer to a submitted article and didn't understand what I should do very well. Here are the tests I performed: We first used principal components analysis (PCA) to ...
1
vote
0answers
11 views

Conditional distribution of serial correlated errors

So I have a gls model, using the nlme package. It has a CAR1 correlation structure. Is it right that the conditional distribution of it's errors will be: $$ \varepsilon_i | \varepsilon_j \sim ...
2
votes
1answer
32 views

is it possible to check Czuprow's coefficient of the convergence in R package?

just wondering - is it possible to calculate Czuprow's coefficient of the convergence in R package? if so, is there some dedicated package for that purpose? thanks in advance
2
votes
0answers
90 views

Interpolating time series wind data using correlation

Is there a way to use correlation to interpolate missing data? I know the wind speed in 6 locations every hour. This shows the correlation between the separate locations. Hourly Data I know the wind ...
3
votes
1answer
151 views

Generating a correlated data matrix where both observations and variables are correlated

I am trying to generate a simulated data matrix that is correlated by both observation and variable directions. So far I know how to do this for variable x variable. ...
1
vote
0answers
40 views

Correlation between two variables measured in separate experiments in R

I'm trying to show a correlation between growth in a petri dish of some fungi and its effect on a plant. I have ten strains of fungi which I tested in the plant and in petri dishes. I can put data ...
0
votes
0answers
29 views

Not getting correct lag values in output

I am using R to calculate lagged correlation. Instead of getting lag values -20 to 20, I am getting the following values: ...
8
votes
1answer
37 views

When should I use each of these methods to calculate correlation?

I am using R for data analysis. R provides a corr function for calculating the correlation. This function provides three different approaches/algorithms to ...
3
votes
1answer
134 views

What does this residuals versus fitted plot mean about my model?

I have a model that attempts to predict a nation's quality of life index by it's moral indifference to contraception and moral rejection of gambling. Initially the model contained several predictors, ...
2
votes
2answers
124 views

Building the connection between cosine similarity and correlation in R

According to some articles (e.g. here) correlation is just a centered version of cosine similarity. I use the following code to calculate the cosine similarity matrix of the column vectors of a matrix ...
2
votes
1answer
194 views
2
votes
2answers
146 views

Why is the Pearson correlation 1 when only two data values are available?

I am trying to obtain a Pearson correlation between 6 different variables (represented by columns in the matrix below) with two datapoints each (rows). This is the matrix: ...
0
votes
1answer
63 views

Investigating relationships between variables- multiple and simple linear regression

please help a sociologist struggling to get to grips with R and statistics in general..! I've got a data set with 11 variables. I need to investigate the possible relationships between one of the ...
2
votes
1answer
127 views

How important is the correlation coefficient's variance in linear regression?

R doesn't return the correlation coefficient's variance (or standard error) when coding summary(linmod), linmod being a linear ...
0
votes
1answer
48 views

Bivariate random variable with R [closed]

I am trying to transform this Matlab code into R. My goal is to generate a bivariate random variable with a pre-specified correlation. The code uses the idea of t-copula. I can't figure out how to ...
0
votes
0answers
27 views

Choosing the best time series for forecasting

I have set of time series for various days (same frequency and source). I need to choose a subset of it, and they together will forecast future values. Currently I am simply using X out of Y time ...
1
vote
1answer
90 views

Multiple comparisons for correlation matrix?

Does the computation of an N x N correlation matrix for N unrelated variables require multiple comparisons correction for all the computed pairwise correlations (assuming each computed correlation is ...
1
vote
0answers
43 views

How to measure/clarify a possible relationship between two spatial points using R

I'm quite new to the area of spatial statistics, but I'm very interest in some general principles. The last two weeks I've created an example dataset, which contains three datsets. A dataset of ill ...
0
votes
0answers
17 views

Influence of using differences or means in order to find correlations

I have a big dataset I want to find correlations in. So far I have been unsuccessful. I'm wondering whether it would be a good idea to either: Take the average of all neighboring entries in all my ...
0
votes
0answers
62 views

Low number of replicates DGE analysis

I am using DESeq for DGE analysis. I have STRANDED RNA-Seq data for 4 developmental stages with no replicates. To have a more reliable DGE I should have replicates and so I obtained (from another lab ...
1
vote
0answers
29 views

How to predict the model fit of a particular % of a sample?

I have a large number of projects (about 300). Each project contains a set of test cases. Each test case can result in a success or a failure. The dataset looks like this. Original: ...
1
vote
2answers
136 views

How to determine the correlation between 2 time series while controlling for a 3rd?

I would like to determine the relationship between two variables after controlling for a third. Specifically, I want to know if the prices of mercury and gold over time are correlated with each other ...
1
vote
0answers
88 views

Correlation between the proportion derived from the data of different size

I want to obtain a correlation between the accuracy of two linguistic features by language learners. The learners wrote a number of essays, and the number of correct and incorrect use of the article ...
3
votes
1answer
157 views

Generate two variables with precise pre-specified correlation

I want to generate two variables with (pseudo-) random numbers with an exact pearson's r. How do I do that? Python and/or R solutions would be nice! I am able to generate random data that ...
3
votes
0answers
1k views

How to test and avoid multicollinearity in mixed linear model?

I am currently running some mixed effect linear models. I am using the package "lme4" in R. My models take the form: ...
0
votes
1answer
104 views

Generating correlated distributions with a certain mean and standard deviation?

Given a distribution A with a mean of $\mu_1$ and standard deviation of $\sigma_1$, how can I generate: Distribution B with a mean of $\mu_2$ and standard deviation of $\sigma_2$ and a correlation ...
1
vote
0answers
88 views

Large discrepancy between confidence intervals for correlation coefficient using bootstrap and Fisher's Z transform

I found that the default confidence intervals provided by cor.test (Fisher's Z transform according to the help) are quite different from the nonparametric boostrap confidence intervals for the below ...
6
votes
1answer
305 views

Variables lack correlation, but have pattern

Below is the graph of two variables, X and Y, each representing count data. N=348. Note the scales of the axes: Y is very approximately lognormal, but X has no decent fit (including Poisson, ...
0
votes
0answers
291 views

Multidimensional scaling in R with Spearman's rank correlation

I'm new to MDS, but I found some good starter code here (http://mhermans.net/static/postdata/r-examples/neighbours-mds/neighbours-mds-example.html) and which I borrowed for below. The code works fine, ...
2
votes
0answers
99 views

Bayesian method to compare correlations

I have read up on Bayesian methods enough now to feel that I would rather use Bayesian analysis over Frequentist, the trouble now is finding the correct tools... I have data from an experiment with ...
0
votes
1answer
124 views

Calculating correlation coefficient

a <- c(10,11) b <- c(2,3) The covariance (C) betweena and ...
2
votes
0answers
60 views

How to check if two variables are dependent given a third variable?

In R, I have a dataset of many variables and based on correlation matrix I see that some of the variable are correlate with the others. For simplicity, let's assume ...
2
votes
1answer
262 views

How can I look for a correlation between dependent variables in a repeated-measures/within-subjects design?

I have a 2x3 within-subjects design, with two different dependent variables (DVs). I would like to know if the two DVs are correlated or not. Here is an example of what the data look like, e.g. a ...