What do you want to save?
Add Code snippet
New code examples
-
TypeScript 2022-03-27 08:30:01
unit test naming convention
MethodName_StateUnderTest_ExpectedBehavior Example: add_twoPositiveIntegers_returnsTheirSum() Variant: Add_TwoPositiveIntegers_ReturnsTheirSum() Note: This is not camel case, so the question of whether to start each new chunk with a capital is up... Add solution -
Python 2022-03-05 16:40:15
numpy count occurrences in interval array
# credit to Stack Overflow user in source link # a is a numpy array # Note: the following syntax allows you to count the number of elements x # of the array such that 25 < x < 100 ((a > 25) & (a < 100)).sum() Add solution -
Other 2022-03-03 15:50:03
naive bayes classifier sklearn
from sklearn.datasets import load_iris from sklearn.model_selection import train_test_split from sklearn.naive_bayes import GaussianNB X, y = load_iris(return_X_y=True) X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.5, random_state=... Add solution -
Python 2022-02-23 01:25:06
check for missing values by column in pandas
df.isnull().sum().sum() 5 Add solution
Best helpers
Ranking is empty