Skip to content

Commit 9fc8428

Browse files
committed
Pushing the docs to dev/ for branch: master, commit 9b75a81b2dd89daf93e483b3b32ea1759edaf937
1 parent b4960ef commit 9fc8428

File tree

974 files changed

+3117
-3113
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

974 files changed

+3117
-3113
lines changed
2 Bytes
Binary file not shown.
2 Bytes
Binary file not shown.

dev/_downloads/plot_lasso_and_elasticnet.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"execution_count": null,
4343
"cell_type": "code",
4444
"source": [
45-
"np.random.seed(42)\n\nn_samples, n_features = 50, 200\nX = np.random.randn(n_samples, n_features)\ncoef = 3 * np.random.randn(n_features)\ninds = np.arange(n_features)\nnp.random.shuffle(inds)\ncoef[inds[10:]] = 0 # sparsify coef\ny = np.dot(X, coef)\n\n# add noise\ny += 0.01 * np.random.normal((n_samples,))\n\n# Split data in train set and test set\nn_samples = X.shape[0]\nX_train, y_train = X[:n_samples // 2], y[:n_samples // 2]\nX_test, y_test = X[n_samples // 2:], y[n_samples // 2:]"
45+
"np.random.seed(42)\n\nn_samples, n_features = 50, 200\nX = np.random.randn(n_samples, n_features)\ncoef = 3 * np.random.randn(n_features)\ninds = np.arange(n_features)\nnp.random.shuffle(inds)\ncoef[inds[10:]] = 0 # sparsify coef\ny = np.dot(X, coef)\n\n# add noise\ny += 0.01 * np.random.normal(size=n_samples)\n\n# Split data in train set and test set\nn_samples = X.shape[0]\nX_train, y_train = X[:n_samples // 2], y[:n_samples // 2]\nX_test, y_test = X[n_samples // 2:], y[n_samples // 2:]"
4646
],
4747
"outputs": [],
4848
"metadata": {

dev/_downloads/plot_lasso_and_elasticnet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
y = np.dot(X, coef)
2929

3030
# add noise
31-
y += 0.01 * np.random.normal((n_samples,))
31+
y += 0.01 * np.random.normal(size=n_samples)
3232

3333
# Split data in train set and test set
3434
n_samples = X.shape[0]

dev/_downloads/scikit-learn-docs.pdf

6.7 KB
Binary file not shown.
-74 Bytes
-74 Bytes
23 Bytes
23 Bytes
96 Bytes

0 commit comments

Comments
 (0)