API：How can I apply a function on rolling DataFrames 
#### well, my function's input is ndarray-like and it's output is a scaler. The question is I have no method to apply this function on rolling object.

```python
from sklearn.decomposition import PCA

df = pd.DataFrame({"A": [1, 2, 3, 4, 5, 6, 7, 8], "B": [2, 3, 4, 5, 6, 7, 8, 9]})

def first_variance(X):
    pca = PCA(n_components=1)
    pca.fit(X)
    return pca.explained_variance_

df.rolling(4).apply(first_variance)

```
#### The domo is incorrect because the "apply" method only can apply by index or column.
