quantopian / alphalens

Performance analysis of predictive (alpha) stock factors
http://quantopian.github.io/alphalens
Apache License 2.0
3.18k stars 1.12k forks source link

Should factor_alpha_beta return a tstat? #376

Open jsmidt opened 4 years ago

jsmidt commented 4 years ago

Problem Description

The function description documentation for alphalens.performance.factor_alpha_beta says "Compute the alpha (excess returns), alpha t-stat (alpha significance), and beta (market exposure) of a factor. "

The return documentation says "A list containing the alpha, beta, a t-stat(alpha) for the given factor and forward returns."

I am assuming "a t-stat" means "and t-stat" given the documentation for the function description?

In at least 0.4.0 and the head version if I run:

alpha = al.performance.factor_alpha_beta(factor_data, group_adjust=True)
print (alphas)

I get "Ann. alpha" and "beta" but no t-stat. The code in the head version, assuming I understand it, is not showing a t-stat entry to be returned. It would be very helpful if this function did return t-stat(alpha).

Thanks!