ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Python Data Science Snippets

📊 Collection of Sublime Text snippets for data science and machine learning in Python (Imports, NumPy, Pandas, Matplotlib, Scikit-learn, Keras, PyTorch, etc)

Details

Installs

  • Total 1K
  • Win 707
  • Mac 175
  • Linux 218
Sep 29 Sep 28 Sep 27 Sep 26 Sep 25 Sep 24 Sep 23 Sep 22 Sep 21 Sep 20 Sep 19 Sep 18 Sep 17 Sep 16 Sep 15 Sep 14 Sep 13 Sep 12 Sep 11 Sep 10 Sep 9 Sep 8 Sep 7 Sep 6 Sep 5 Sep 4 Sep 3 Sep 2 Sep 1 Aug 31 Aug 30 Aug 29 Aug 28 Aug 27 Aug 26 Aug 25 Aug 24 Aug 23 Aug 22 Aug 21 Aug 20 Aug 19 Aug 18 Aug 17 Aug 16 Aug 15
Windows 1 3 2 2 0 5 2 1 4 1 1 0 2 1 4 1 0 0 0 2 8 1 2 6 2 0 2 2 2 0 5 3 1 0 2 3 2 1 0 1 1 1 0 3 2 1
Mac 0 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 2 0 0 2 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 2 0
Linux 1 1 0 1 1 1 1 2 0 0 0 0 1 3 1 0 1 0 0 0 2 1 0 1 1 1 0 2 2 1 0 1 0 0 2 1 0 0 0 1 2 2 1 2 0 1

Readme

Source
raw.​githubusercontent.​com

📊 Python Data Science Snippets

Downloads Tag Repo size License

Python Data Science Snippets is a collection of Sublime Text snippets for data science and machine learning in Python.

💻 Installation

The easiest way to install Python Data Science Snippets is through Package Control. After it is enabled inside Sublime Text, open the command palette and find Package Control: Install Package and press ENTER. Then, find Python Data Science Snippets in the list. Press ENTER again, and this package is installed!

📈 Snippets

Imports

Import snippets start with i followed by the package's import alias.

Trigger Description
ikeras from tensorflow import keras
inp import numpy as np
ipd import pandas as pd
iplt import matplotlib.pyplot as plt
isklearn from sklearn.$1 import $2
isns import seaborn as sns
itf import tensorflow as tf
itorch import torch
inn from torch import nn
idl from torch.utils.data import DataLoader

NumPy

Trigger Description
arange np.arange
array np.array
linspace np.linspace
logspace np.logspace
ones np.ones
zeros np.zeros

Pandas

Trigger Description
apply df.apply
columns df.columns
describe df.describe
df pd.DataFrame
dropna df.dropna
fillna df.fillna
groupby df.groupby
head df.head
read_csv pd.read_csv
rename df.rename
sample df.sample
ser pd.Series
tail df.tail
to_csv df.to_csv
to_datetime pd.to_datetime

Matplotlib

Trigger Description
bar plt.bar
legend plt.legend
pie plt.pie
plot plt.plot
scatter plt.scatter
show plt.show
subplots plt.subplots
title plt.title
xlabel plt.xlabel
ylabel plt.ylabel

Scikit-learn

Trigger Description
knn KNeighborsClassifier
linreg LinearRegression
logreg LogisticRegression
rfc RandomForestClassifier
tts train_test_split

Keras

Trigger Description
compile model.compile
evaluate model.evaluate
fit model.fit
layer keras.layers.layer
load_model keras.models.load_model
predict model.predict
save model.save
sequential keras.Sequential

PyTorch

Trigger Description
dataloader torch.utils.data.DataLoader
device torch.device (cuda/cpu)
module torch.nn.Module

The snippet files are in the snippets folder of this GitHub repository.