Variance explained by the components of an pca, zero from a certain moment

### Describe the bug

I'm doing a PCA on data of quite large dimension (about 5000 individuals, about 3000 variables). 

The problem presented does not depend on the type of data, I find it with my data but also with synthetically generated data (see example below). 

I realize my pca by specifying that I wish to calculate a number of components corresponding to 90% of the explained variance, to avoid a too long calculation time (and to be able to compare it to others, realized on similar data).

For 3000 variables, the PCA calculates about 1800 components in my example, it may seem a lot but it is logical because the random data generation is based on a normal distribution. In my personal data (not reproducible, so not provided here), I have less components (about 200). 

Whatever the data, the problem remains the same.  From a certain threshold of components, the explained variance becomes zero. When we plot the cumulative explained variance as a function of the components, the curve has "at the beginning" a logarithm shape, then suddenly, it becomes a constant, which is not a threshold that would appear progressively. This means that the explained variance for the components from this threshold is 0. However, the total cumulative variance is still not 90%, as specified in the parameters of the pca, but, depending on the repetitions, rather 70/80%.

I don't understand what is going on, is it a rounding error or something else. 

![image](https://user-images.githubusercontent.com/56197324/160409854-b7b278c9-c83c-4efd-86ff-c83471f158b5.png)

### Steps/Code to Reproduce

```py
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt

from sklearn import decomposition
from sklearn import preprocessing


#synthetic data
df = pd.DataFrame(np.random.randint(-1000,1000,size=(3000, 5000))) 

#scale and pca
X = df.values 
std_scale = preprocessing.StandardScaler().fit(X)      
X_scaled = std_scale.transform(X)         
pca = decomposition.PCA(n_components= 0.9)
coordinates = pca.fit_transform(X_scaled)      
 
#cumsum of explained variance ratio
df = pd.DataFrame(coordinates)
var=np.cumsum(np.round(pca.explained_variance_ratio_, decimals=3)*100)
df2 = pd.DataFrame(var, columns = ['cumulative_explained_variance'])
df2['comp_index'] = range(1,len(df2.index)+1)

#plot
df2.plot(x ='comp_index', y='cumulative_explained_variance (%)', kind = 'scatter')	
plt.show()
```

### Expected Results

A progressive decreasing evolution of the variances explained by components

### Actual Results

An abrupt shift from a decreasing explained variance per component to a zero explained variance for all components after a certain threshold

### Versions

```shell
System:
    python: 3.9.5 (default, May 18 2021, 19:34:48)  [GCC 7.3.0]
executable: /home/renoult/anaconda3/envs/cefe/bin/python3
   machine: Linux-5.14.0-1029-oem-x86_64-with-glibc2.31

Python dependencies:
          pip: 21.0.1
   setuptools: 49.6.0.post20210108
      sklearn: 0.24.1
        numpy: 1.21.1
        scipy: 1.6.2
       Cython: 0.29.23
       pandas: 1.2.4
   matplotlib: 3.4.1
       joblib: 0.17.0
threadpoolctl: 2.1.0

Built with OpenMP: True
```

COMMENT:
With the answer from https://github.com/scikit-learn/scikit-learn/issues/22974#issuecomment-1080834333, I am closing this issue.

Labels: module:decomposition