help-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-gsl] Pearson's and stride (gsl_stats_correlation)


From: M Yilmaz
Subject: [Help-gsl] Pearson's and stride (gsl_stats_correlation)
Date: Fri, 15 May 2009 15:20:05 -0400

What is the stride referred to in the GSL library functions?  In particular,
the pearson's formula defined:

double gsl_stats_correlation (const double data1[], const size_t stride1,
const double data2[], const size_t stride2, const size_t n)

I have a couple of vector<double> types I am inputting here and I don't feel
all that confident in the results with stride1 and stride2 simply set to 1
(They seem a little too well correlated).

Don't take this too literally, but the gist is:
i.e. gsl_stats_correlation(&vector[0],1,&vector2[0],1,vector.size() );

I have been looking for examples and through the manual and I still can't
figure it out.  Should I change this from 1 to something like a
size_of(double) * vector.size() ?  What is the right way to handle the
stride?


Thanks in advance!
-- 
Mehmet Yilmaz


reply via email to

[Prev in Thread] Current Thread [Next in Thread]