commit 7ee4420c104f81e844c79a8cc7cead356dcc4118 Author: wehub-resource-sync Date: Mon Jul 13 13:39:55 2026 +0800 chore: import upstream snapshot with attribution diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml new file mode 100644 index 0000000..a5a8d93 --- /dev/null +++ b/.github/workflows/python-app.yml @@ -0,0 +1,26 @@ +name: Tests + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + timeout-minutes: 5 + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up Python 3.12 + uses: actions/setup-python@v4 + with: + python-version: 3.12 + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install flake8 pytest + pip install -r requirements.txt + - name: Test with pytest + run: | + pytest diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e240d8d --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +*.pyc +build/ +dist/ +mla.egg-info/ +.cache +*.swp +.idea \ No newline at end of file diff --git a/AUTHORS b/AUTHORS new file mode 100644 index 0000000..1f9f89c --- /dev/null +++ b/AUTHORS @@ -0,0 +1,19 @@ +Artem Golubin +Anebi Agbo +Convex Path +James Chevalier +Jiancheng +KaiMin Lai +Nguyễn Tuấn +Nicolas Hug +Xiaochun Ma +Yiran Sheng +brady salz +junwang007 +keineahnung2345 +lucaskolstad +vincent tang +xq5he +LanderTome +therickli +Andrew Melnik diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b0437a5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,10 @@ +FROM python:3 + +RUN mkdir -p /var/app +WORKDIR /var/app +COPY . /var/app + +# install scipy & numpy +# install required packages +RUN pip install scipy numpy && \ + pip install . diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..6620ff6 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2016-2020 Artem Golubin + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 0000000..de513f2 --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1 @@ +recursive-include mla/datasets/data * diff --git a/README.md b/README.md new file mode 100644 index 0000000..bd3b4aa --- /dev/null +++ b/README.md @@ -0,0 +1,49 @@ +# Machine learning algorithms +A collection of minimal and clean implementations of machine learning algorithms. + +### Why? +This project is targeting people who want to learn internals of ml algorithms or implement them from scratch. +The code is much easier to follow than the optimized libraries and easier to play with. +All algorithms are implemented in Python, using numpy, scipy and autograd. + +### Implemented: +* [Deep learning (MLP, CNN, RNN, LSTM)](mla/neuralnet) +* [Linear regression, logistic regression](mla/linear_models.py) +* [Random Forests](mla/ensemble/random_forest.py) +* [Support vector machine (SVM) with kernels (Linear, Poly, RBF)](mla/svm) +* [K-Means](mla/kmeans.py) +* [Gaussian Mixture Model](mla/gaussian_mixture.py) +* [K-nearest neighbors](mla/knn.py) +* [Naive bayes](mla/naive_bayes.py) +* [Principal component analysis (PCA)](mla/pca.py) +* [Factorization machines](mla/fm.py) +* [Restricted Boltzmann machine (RBM)](mla/rbm.py) +* [t-Distributed Stochastic Neighbor Embedding (t-SNE)](mla/tsne.py) +* [Gradient Boosting trees (also known as GBDT, GBRT, GBM, XGBoost)](mla/ensemble/gbm.py) +* [Reinforcement learning (Deep Q learning)](mla/rl) + + +### Installation +```sh + git clone https://github.com/rushter/MLAlgorithms + cd MLAlgorithms + pip install scipy numpy + python setup.py develop +``` +### How to run examples without installation +```sh + cd MLAlgorithms + python -m examples.linear_models +``` +### How to run examples within Docker +```sh + cd MLAlgorithms + docker build -t mlalgorithms . + docker run --rm -it mlalgorithms bash + python -m examples.linear_models +``` +### Contributing + +Your contributions are always welcome! +Feel free to improve existing code, documentation or implement new algorithm. +Please open an issue to propose your changes if they are big enough. diff --git a/README.wehub.md b/README.wehub.md new file mode 100644 index 0000000..34024c2 --- /dev/null +++ b/README.wehub.md @@ -0,0 +1,7 @@ +# WeHub 来源说明 + +- 原始项目:`rushter/MLAlgorithms` +- 原始仓库:https://github.com/rushter/MLAlgorithms +- 导入方式:上游默认分支的最新快照 +- 原作者、版权和许可证信息以原始仓库及本仓库 LICENSE 为准 +- 本文件仅用于记录来源,不代表 WeHub 是原项目作者 diff --git a/examples/__init__.py b/examples/__init__.py new file mode 100644 index 0000000..57d631c --- /dev/null +++ b/examples/__init__.py @@ -0,0 +1 @@ +# coding: utf-8 diff --git a/examples/gaussian_mixture.py b/examples/gaussian_mixture.py new file mode 100644 index 0000000..e8dfce1 --- /dev/null +++ b/examples/gaussian_mixture.py @@ -0,0 +1,46 @@ +import random +import numpy as np +import matplotlib.pyplot as plt +from sklearn import datasets +from mla.kmeans import KMeans +from mla.gaussian_mixture import GaussianMixture + +random.seed(1) +np.random.seed(6) + + +def make_clusters(skew=True, *arg, **kwargs): + X, y = datasets.make_blobs(*arg, **kwargs) + if skew: + nrow = X.shape[1] + for i in np.unique(y): + X[y == i] = X[y == i].dot(np.random.random((nrow, nrow)) - 0.5) + return X, y + + +def KMeans_and_GMM(K): + COLOR = "bgrcmyk" + + X, y = make_clusters(skew=True, n_samples=1500, centers=K) + _, axes = plt.subplots(1, 3) + + # Ground Truth + axes[0].scatter(X[:, 0], X[:, 1], c=[COLOR[int(assignment)] for assignment in y]) + axes[0].set_title("Ground Truth") + + # KMeans + kmeans = KMeans(K=K, init="++") + kmeans.fit(X) + kmeans.predict() + axes[1].set_title("KMeans") + kmeans.plot(ax=axes[1], holdon=True) + + # Gaussian Mixture + gmm = GaussianMixture(K=K, init="kmeans") + gmm.fit(X) + axes[2].set_title("Gaussian Mixture") + gmm.plot(ax=axes[2]) + + +if __name__ == "__main__": + KMeans_and_GMM(4) diff --git a/examples/gbm.py b/examples/gbm.py new file mode 100644 index 0000000..f3f85fd --- /dev/null +++ b/examples/gbm.py @@ -0,0 +1,70 @@ +import logging + +from sklearn.datasets import make_classification +from sklearn.datasets import make_regression +from sklearn.metrics import roc_auc_score + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split + +from mla.ensemble.gbm import GradientBoostingClassifier, GradientBoostingRegressor +from mla.metrics.metrics import mean_squared_error + +logging.basicConfig(level=logging.DEBUG) + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=350, + n_features=15, + n_informative=10, + random_state=1111, + n_classes=2, + class_sep=1.0, + n_redundant=0, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.15, random_state=1111 + ) + + model = GradientBoostingClassifier( + n_estimators=50, max_depth=4, max_features=8, learning_rate=0.1 + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print(predictions) + print(predictions.min()) + print(predictions.max()) + print("classification, roc auc score: %s" % roc_auc_score(y_test, predictions)) + + +def regression(): + # Generate a random regression problem + X, y = make_regression( + n_samples=500, + n_features=5, + n_informative=5, + n_targets=1, + noise=0.05, + random_state=1111, + bias=0.5, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + model = GradientBoostingRegressor(n_estimators=25, max_depth=5, max_features=3) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print( + "regression, mse: %s" + % mean_squared_error(y_test.flatten(), predictions.flatten()) + ) + + +if __name__ == "__main__": + classification() + # regression() diff --git a/examples/kmeans.py b/examples/kmeans.py new file mode 100644 index 0000000..9714c43 --- /dev/null +++ b/examples/kmeans.py @@ -0,0 +1,21 @@ +import numpy as np +from sklearn.datasets import make_blobs + +from mla.kmeans import KMeans + + +def kmeans_example(plot=False): + X, y = make_blobs( + centers=4, n_samples=500, n_features=2, shuffle=True, random_state=42 + ) + clusters = len(np.unique(y)) + k = KMeans(K=clusters, max_iters=150, init="++") + k.fit(X) + k.predict() + + if plot: + k.plot() + + +if __name__ == "__main__": + kmeans_example(plot=True) diff --git a/examples/linear_models.py b/examples/linear_models.py new file mode 100644 index 0000000..9bdb1cd --- /dev/null +++ b/examples/linear_models.py @@ -0,0 +1,60 @@ +import logging + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification +from sklearn.datasets import make_regression + +from mla.linear_models import LinearRegression, LogisticRegression +from mla.metrics.metrics import mean_squared_error, accuracy + +# Change to DEBUG to see convergence +logging.basicConfig(level=logging.ERROR) + + +def regression(): + # Generate a random regression problem + X, y = make_regression( + n_samples=10000, + n_features=100, + n_informative=75, + n_targets=1, + noise=0.05, + random_state=1111, + bias=0.5, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.25, random_state=1111 + ) + + model = LinearRegression(lr=0.01, max_iters=2000, penalty="l2", C=0.03) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print("regression mse", mean_squared_error(y_test, predictions)) + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=1000, + n_features=100, + n_informative=75, + random_state=1111, + n_classes=2, + class_sep=2.5, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + model = LogisticRegression(lr=0.01, max_iters=500, penalty="l1", C=0.01) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print("classification accuracy", accuracy(y_test, predictions)) + + +if __name__ == "__main__": + regression() + classification() diff --git a/examples/naive_bayes.py b/examples/naive_bayes.py new file mode 100644 index 0000000..9e051d4 --- /dev/null +++ b/examples/naive_bayes.py @@ -0,0 +1,31 @@ +from sklearn.datasets import make_classification +from sklearn.metrics import roc_auc_score +from sklearn.model_selection import train_test_split + +from mla.naive_bayes import NaiveBayesClassifier + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=1000, + n_features=10, + n_informative=10, + random_state=1111, + n_classes=2, + class_sep=2.5, + n_redundant=0, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + model = NaiveBayesClassifier() + model.fit(X_train, y_train) + predictions = model.predict(X_test)[:, 1] + + print("classification accuracy", roc_auc_score(y_test, predictions)) + + +if __name__ == "__main__": + classification() diff --git a/examples/nearest_neighbors.py b/examples/nearest_neighbors.py new file mode 100644 index 0000000..f551ab0 --- /dev/null +++ b/examples/nearest_neighbors.py @@ -0,0 +1,59 @@ +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification +from sklearn.datasets import make_regression +from scipy.spatial import distance + +from mla import knn +from mla.metrics.metrics import mean_squared_error, accuracy + + +def regression(): + # Generate a random regression problem + X, y = make_regression( + n_samples=500, + n_features=5, + n_informative=5, + n_targets=1, + noise=0.05, + random_state=1111, + bias=0.5, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.25, random_state=1111 + ) + + model = knn.KNNRegressor(k=5, distance_func=distance.euclidean) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print("regression mse", mean_squared_error(y_test, predictions)) + + +def classification(): + X, y = make_classification( + n_samples=500, + n_features=5, + n_informative=5, + n_redundant=0, + n_repeated=0, + n_classes=3, + random_state=1111, + class_sep=1.5, + ) + + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + clf = knn.KNNClassifier(k=5, distance_func=distance.euclidean) + + clf.fit(X_train, y_train) + predictions = clf.predict(X_test) + print("classification accuracy", accuracy(y_test, predictions)) + + +if __name__ == "__main__": + regression() + classification() diff --git a/examples/nnet_convnet_mnist.py b/examples/nnet_convnet_mnist.py new file mode 100644 index 0000000..4161a06 --- /dev/null +++ b/examples/nnet_convnet_mnist.py @@ -0,0 +1,57 @@ +import logging + +from mla.datasets import load_mnist +from mla.metrics import accuracy +from mla.neuralnet import NeuralNet +from mla.neuralnet.layers import ( + Activation, + Convolution, + MaxPooling, + Flatten, + Dropout, + Parameters, +) +from mla.neuralnet.layers import Dense +from mla.neuralnet.optimizers import Adadelta +from mla.utils import one_hot + +logging.basicConfig(level=logging.DEBUG) + + +# Load MNIST dataset +X_train, X_test, y_train, y_test = load_mnist() + +# Normalize data +X_train /= 255.0 +X_test /= 255.0 + +y_train = one_hot(y_train.flatten()) +y_test = one_hot(y_test.flatten()) +print(X_train.shape, X_test.shape, y_train.shape, y_test.shape) + +# Approx. 15-20 min. per epoch +model = NeuralNet( + layers=[ + Convolution(n_filters=32, filter_shape=(3, 3), padding=(1, 1), stride=(1, 1)), + Activation("relu"), + Convolution(n_filters=32, filter_shape=(3, 3), padding=(1, 1), stride=(1, 1)), + Activation("relu"), + MaxPooling(pool_shape=(2, 2), stride=(2, 2)), + Dropout(0.5), + Flatten(), + Dense(128), + Activation("relu"), + Dropout(0.5), + Dense(10), + Activation("softmax"), + ], + loss="categorical_crossentropy", + optimizer=Adadelta(), + metric="accuracy", + batch_size=128, + max_epochs=3, +) + +model.fit(X_train, y_train) +predictions = model.predict(X_test) +print(accuracy(y_test, predictions)) diff --git a/examples/nnet_mlp.py b/examples/nnet_mlp.py new file mode 100644 index 0000000..484989b --- /dev/null +++ b/examples/nnet_mlp.py @@ -0,0 +1,95 @@ +import logging + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification +from sklearn.datasets import make_regression +from sklearn.metrics import roc_auc_score + +from mla.metrics.metrics import mean_squared_error +from mla.neuralnet import NeuralNet +from mla.neuralnet.constraints import MaxNorm +from mla.neuralnet.layers import Activation, Dense, Dropout +from mla.neuralnet.optimizers import Adadelta, Adam +from mla.neuralnet.parameters import Parameters +from mla.neuralnet.regularizers import L2 +from mla.utils import one_hot + +logging.basicConfig(level=logging.DEBUG) + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=1000, + n_features=100, + n_informative=75, + random_state=1111, + n_classes=2, + class_sep=2.5, + ) + y = one_hot(y) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.15, random_state=1111 + ) + + model = NeuralNet( + layers=[ + Dense(256, Parameters(init="uniform", regularizers={"W": L2(0.05)})), + Activation("relu"), + Dropout(0.5), + Dense(128, Parameters(init="normal", constraints={"W": MaxNorm()})), + Activation("relu"), + Dense(2), + Activation("softmax"), + ], + loss="categorical_crossentropy", + optimizer=Adadelta(), + metric="accuracy", + batch_size=64, + max_epochs=25, + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print("classification accuracy", roc_auc_score(y_test[:, 0], predictions[:, 0])) + + +def regression(): + # Generate a random regression problem + X, y = make_regression( + n_samples=5000, + n_features=25, + n_informative=25, + n_targets=1, + random_state=100, + noise=0.05, + ) + y *= 0.01 + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + model = NeuralNet( + layers=[ + Dense(64, Parameters(init="normal")), + Activation("linear"), + Dense(32, Parameters(init="normal")), + Activation("linear"), + Dense(1), + ], + loss="mse", + optimizer=Adam(), + metric="mse", + batch_size=256, + max_epochs=15, + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print("regression mse", mean_squared_error(y_test, predictions.flatten())) + + +if __name__ == "__main__": + classification() + regression() diff --git a/examples/nnet_rnn_binary_add.py b/examples/nnet_rnn_binary_add.py new file mode 100644 index 0000000..5057cc5 --- /dev/null +++ b/examples/nnet_rnn_binary_add.py @@ -0,0 +1,78 @@ +import logging +from itertools import combinations, islice + +import numpy as np + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split + +from mla.metrics import accuracy +from mla.neuralnet import NeuralNet +from mla.neuralnet.layers import Activation, TimeDistributedDense +from mla.neuralnet.layers.recurrent import LSTM +from mla.neuralnet.optimizers import Adam + +logging.basicConfig(level=logging.DEBUG) + + +def addition_dataset(dim=10, n_samples=10000, batch_size=64): + """Generate binary addition dataset. + http://devankuleindiren.com/Projects/rnn_arithmetic.php + """ + binary_format = "{:0" + str(dim) + "b}" + + # Generate all possible number combinations + combs = list(islice(combinations(range(2 ** (dim - 1)), 2), n_samples)) + + # Initialize empty arrays + X = np.zeros((len(combs), dim, 2), dtype=np.uint8) + y = np.zeros((len(combs), dim, 1), dtype=np.uint8) + + for i, (a, b) in enumerate(combs): + # Convert numbers to binary format + X[i, :, 0] = list(reversed([int(x) for x in binary_format.format(a)])) + X[i, :, 1] = list(reversed([int(x) for x in binary_format.format(b)])) + + # Generate target variable (a+b) + y[i, :, 0] = list(reversed([int(x) for x in binary_format.format(a + b)])) + + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.2, random_state=1111 + ) + + # Round number of examples for batch processing + train_b = (X_train.shape[0] // batch_size) * batch_size + test_b = (X_test.shape[0] // batch_size) * batch_size + X_train = X_train[0:train_b] + y_train = y_train[0:train_b] + + X_test = X_test[0:test_b] + y_test = y_test[0:test_b] + return X_train, X_test, y_train, y_test + + +def addition_problem(ReccurentLayer): + X_train, X_test, y_train, y_test = addition_dataset(8, 5000) + + print(X_train.shape, X_test.shape) + model = NeuralNet( + layers=[ReccurentLayer, TimeDistributedDense(1), Activation("sigmoid")], + loss="mse", + optimizer=Adam(), + metric="mse", + batch_size=64, + max_epochs=15, + ) + model.fit(X_train, y_train) + predictions = np.round(model.predict(X_test)) + predictions = np.packbits(predictions.astype(np.uint8)) + y_test = np.packbits(y_test.astype(np.int)) + print(accuracy(y_test, predictions)) + + +# RNN +# addition_problem(RNN(16, parameters=Parameters(constraints={'W': SmallNorm(), 'U': SmallNorm()}))) +# LSTM +addition_problem(LSTM(16)) diff --git a/examples/nnet_rnn_text_generation.py b/examples/nnet_rnn_text_generation.py new file mode 100644 index 0000000..50f6ff0 --- /dev/null +++ b/examples/nnet_rnn_text_generation.py @@ -0,0 +1,82 @@ +from __future__ import print_function + +import logging +import random + +import numpy as np +import sys + +from mla.datasets import load_nietzsche +from mla.neuralnet import NeuralNet +from mla.neuralnet.constraints import SmallNorm +from mla.neuralnet.layers import Activation, Dense +from mla.neuralnet.layers.recurrent import LSTM, RNN +from mla.neuralnet.optimizers import RMSprop + +logging.basicConfig(level=logging.DEBUG) + + +# Example taken from: https://github.com/fchollet/keras/blob/master/examples/lstm_text_generation.py + + +def sample(preds, temperature=1.0): + # helper function to sample an index from a probability array + preds = np.asarray(preds).astype("float64") + preds = np.log(preds) / temperature + exp_preds = np.exp(preds) + preds = exp_preds / np.sum(exp_preds) + probas = np.random.multinomial(1, preds, 1) + return np.argmax(probas) + + +X, y, text, chars, char_indices, indices_char = load_nietzsche() +# Round the number of sequences for batch processing +items_count = X.shape[0] - (X.shape[0] % 64) +maxlen = X.shape[1] +X = X[0:items_count] +y = y[0:items_count] + +print(X.shape, y.shape) +# LSTM OR RNN +# rnn_layer = RNN(128, return_sequences=False) +rnn_layer = LSTM(128, return_sequences=False) + +model = NeuralNet( + layers=[ + rnn_layer, + # Flatten(), + # TimeStepSlicer(-1), + Dense(X.shape[2]), + Activation("softmax"), + ], + loss="categorical_crossentropy", + optimizer=RMSprop(learning_rate=0.01), + metric="accuracy", + batch_size=64, + max_epochs=1, + shuffle=False, +) + +for _ in range(25): + model.fit(X, y) + start_index = random.randint(0, len(text) - maxlen - 1) + + generated = "" + sentence = text[start_index : start_index + maxlen] + generated += sentence + print('----- Generating with seed: "' + sentence + '"') + sys.stdout.write(generated) + for i in range(100): + x = np.zeros((64, maxlen, len(chars))) + for t, char in enumerate(sentence): + x[0, t, char_indices[char]] = 1.0 + preds = model.predict(x)[0] + next_index = sample(preds, 0.5) + next_char = indices_char[next_index] + + generated += next_char + sentence = sentence[1:] + next_char + + sys.stdout.write(next_char) + sys.stdout.flush() + print() diff --git a/examples/pca.py b/examples/pca.py new file mode 100644 index 0000000..10321ad --- /dev/null +++ b/examples/pca.py @@ -0,0 +1,39 @@ +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification + +from mla.linear_models import LogisticRegression +from mla.metrics import accuracy +from mla.pca import PCA + +# logging.basicConfig(level=logging.DEBUG) + +# Generate a random binary classification problem. +X, y = make_classification( + n_samples=1000, + n_features=100, + n_informative=75, + random_state=1111, + n_classes=2, + class_sep=2.5, +) + + +X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.25, random_state=1111 +) + +for s in ["svd", "eigen"]: + p = PCA(15, solver=s) + + # fit PCA with training data, not entire dataset + p.fit(X_train) + X_train_reduced = p.transform(X_train) + X_test_reduced = p.transform(X_test) + + model = LogisticRegression(lr=0.001, max_iters=2500) + model.fit(X_train_reduced, y_train) + predictions = model.predict(X_test_reduced) + print("Classification accuracy for %s PCA: %s" % (s, accuracy(y_test, predictions))) diff --git a/examples/random_forest.py b/examples/random_forest.py new file mode 100644 index 0000000..f2fcb44 --- /dev/null +++ b/examples/random_forest.py @@ -0,0 +1,71 @@ +import logging + +import numpy as np +from sklearn.datasets import make_classification +from sklearn.datasets import make_regression +from sklearn.metrics import roc_auc_score, accuracy_score + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split + +from mla.ensemble.random_forest import RandomForestClassifier, RandomForestRegressor +from mla.metrics.metrics import mean_squared_error + +logging.basicConfig(level=logging.DEBUG) + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=500, + n_features=10, + n_informative=10, + random_state=1111, + n_classes=2, + class_sep=2.5, + n_redundant=0, + ) + + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.15, random_state=1111 + ) + + model = RandomForestClassifier(n_estimators=10, max_depth=4) + model.fit(X_train, y_train) + + predictions_prob = model.predict(X_test)[:, 1] + predictions = np.argmax(model.predict(X_test), axis=1) + # print(predictions.shape) + print("classification, roc auc score: %s" % roc_auc_score(y_test, predictions_prob)) + print("classification, accuracy score: %s" % accuracy_score(y_test, predictions)) + + +def regression(): + # Generate a random regression problem + X, y = make_regression( + n_samples=500, + n_features=5, + n_informative=5, + n_targets=1, + noise=0.05, + random_state=1111, + bias=0.5, + ) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.1, random_state=1111 + ) + + model = RandomForestRegressor(n_estimators=50, max_depth=10, max_features=3) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print( + "regression, mse: %s" + % mean_squared_error(y_test.flatten(), predictions.flatten()) + ) + + +if __name__ == "__main__": + classification() + # regression() diff --git a/examples/rbm.py b/examples/rbm.py new file mode 100644 index 0000000..2d16764 --- /dev/null +++ b/examples/rbm.py @@ -0,0 +1,25 @@ +import logging + +import numpy as np + +from mla.rbm import RBM + +logging.basicConfig(level=logging.DEBUG) + + +def print_curve(rbm): + from matplotlib import pyplot as plt + + def moving_average(a, n=25): + ret = np.cumsum(a, dtype=float) + ret[n:] = ret[n:] - ret[:-n] + return ret[n - 1 :] / n + + plt.plot(moving_average(rbm.errors)) + plt.show() + + +X = np.random.uniform(0, 1, (1500, 10)) +rbm = RBM(n_hidden=10, max_epochs=200, batch_size=10, learning_rate=0.1) +rbm.fit(X) +print_curve(rbm) diff --git a/examples/rl_deep_q_learning.py b/examples/rl_deep_q_learning.py new file mode 100644 index 0000000..15a39ff --- /dev/null +++ b/examples/rl_deep_q_learning.py @@ -0,0 +1,37 @@ +import logging + +from mla.neuralnet import NeuralNet +from mla.neuralnet.layers import Activation, Dense +from mla.neuralnet.optimizers import Adam +from mla.rl.dqn import DQN + +logging.basicConfig(level=logging.CRITICAL) + + +def mlp_model(n_actions, batch_size=64): + model = NeuralNet( + layers=[Dense(32), Activation("relu"), Dense(n_actions)], + loss="mse", + optimizer=Adam(), + metric="mse", + batch_size=batch_size, + max_epochs=1, + verbose=False, + ) + return model + + +model = DQN(n_episodes=2500, batch_size=64) +model.init_environment("CartPole-v0") +model.init_model(mlp_model) + +try: + # Train the model + # It can take from 300 to 2500 episodes to solve CartPole-v0 problem due to randomness of environment. + # You can stop training process using Ctrl+C signal + # Read more about this problem: https://gym.openai.com/envs/CartPole-v0 + model.train(render=False) +except KeyboardInterrupt: + pass +# Render trained model +model.play(episodes=100) diff --git a/examples/svm.py b/examples/svm.py new file mode 100644 index 0000000..062a871 --- /dev/null +++ b/examples/svm.py @@ -0,0 +1,42 @@ +import logging + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification + +from mla.metrics.metrics import accuracy +from mla.svm.kernerls import Linear, RBF +from mla.svm.svm import SVM + +logging.basicConfig(level=logging.DEBUG) + + +def classification(): + # Generate a random binary classification problem. + X, y = make_classification( + n_samples=1200, + n_features=10, + n_informative=5, + random_state=1111, + n_classes=2, + class_sep=1.75, + ) + # Convert y to {-1, 1} + y = (y * 2) - 1 + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.2, random_state=1111 + ) + + for kernel in [RBF(gamma=0.1), Linear()]: + model = SVM(max_iter=500, kernel=kernel, C=0.6) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + print( + "Classification accuracy (%s): %s" % (kernel, accuracy(y_test, predictions)) + ) + + +if __name__ == "__main__": + classification() diff --git a/examples/t-sne.py b/examples/t-sne.py new file mode 100644 index 0000000..bd08581 --- /dev/null +++ b/examples/t-sne.py @@ -0,0 +1,28 @@ +import logging + +import matplotlib.pyplot as plt +from sklearn.datasets import make_classification + +from mla.tsne import TSNE + +logging.basicConfig(level=logging.DEBUG) + +X, y = make_classification( + n_samples=500, + n_features=10, + n_informative=5, + n_redundant=0, + random_state=1111, + n_classes=2, + class_sep=2.5, +) + +p = TSNE(2, max_iter=500) +X = p.fit_transform(X) + +colors = ["red", "green"] +for t in range(2): + t_mask = (y == t).astype(bool) + plt.scatter(X[t_mask, 0], X[t_mask, 1], color=colors[t]) + +plt.show() diff --git a/mla/__init__.py b/mla/__init__.py new file mode 100644 index 0000000..7a5d98d --- /dev/null +++ b/mla/__init__.py @@ -0,0 +1,3 @@ +# coding:utf-8 +# copyright: (c) 2016 by Artem Golubin +# license: MIT, see LICENSE for more details. diff --git a/mla/base/__init__.py b/mla/base/__init__.py new file mode 100644 index 0000000..0ffd952 --- /dev/null +++ b/mla/base/__init__.py @@ -0,0 +1,2 @@ +# coding:utf-8 +from .base import * diff --git a/mla/base/base.py b/mla/base/base.py new file mode 100644 index 0000000..caa71e0 --- /dev/null +++ b/mla/base/base.py @@ -0,0 +1,63 @@ +# coding:utf-8 +import numpy as np + + +class BaseEstimator: + y_required = True + fit_required = True + + def _setup_input(self, X, y=None): + """Ensure inputs to an estimator are in the expected format. + + Ensures X and y are stored as numpy ndarrays by converting from an + array-like object if necessary. Enables estimators to define whether + they require a set of y target values or not with y_required, e.g. + kmeans clustering requires no target labels and is fit against only X. + + Parameters + ---------- + X : array-like + Feature dataset. + y : array-like + Target values. By default is required, but if y_required = false + then may be omitted. + """ + if not isinstance(X, np.ndarray): + X = np.array(X) + + if X.size == 0: + raise ValueError("Got an empty matrix.") + + if X.ndim == 1: + self.n_samples, self.n_features = 1, X.shape + else: + self.n_samples, self.n_features = X.shape[0], np.prod(X.shape[1:]) + + self.X = X + + if self.y_required: + if y is None: + raise ValueError("Missed required argument y") + + if not isinstance(y, np.ndarray): + y = np.array(y) + + if y.size == 0: + raise ValueError("The targets array must be no-empty.") + + self.y = y + + def fit(self, X, y=None): + self._setup_input(X, y) + + def predict(self, X=None): + if not isinstance(X, np.ndarray): + X = np.array(X) + + if self.X is not None or not self.fit_required: + return self._predict(X) + else: + raise ValueError("You must call `fit` before `predict`") + + def _predict(self, X=None): + raise NotImplementedError() diff --git a/mla/datasets/__init__.py b/mla/datasets/__init__.py new file mode 100644 index 0000000..d9f114e --- /dev/null +++ b/mla/datasets/__init__.py @@ -0,0 +1,2 @@ +# coding:utf-8 +from mla.datasets.base import * diff --git a/mla/datasets/base.py b/mla/datasets/base.py new file mode 100644 index 0000000..efefbcd --- /dev/null +++ b/mla/datasets/base.py @@ -0,0 +1,78 @@ +# coding:utf-8 +import os + +import numpy as np + + +def get_filename(name): + return os.path.join(os.path.dirname(__file__), name) + + +def load_mnist(): + def load(dataset="training", digits=np.arange(10)): + import struct + from array import array as pyarray + from numpy import array, int8, uint8, zeros + + if dataset == "train": + fname_img = get_filename("data/mnist/train-images-idx3-ubyte") + fname_lbl = get_filename("data/mnist/train-labels-idx1-ubyte") + elif dataset == "test": + fname_img = get_filename("data/mnist/t10k-images-idx3-ubyte") + fname_lbl = get_filename("data/mnist/t10k-labels-idx1-ubyte") + else: + raise ValueError("Unexpected dataset name: %r" % dataset) + + flbl = open(fname_lbl, "rb") + magic_nr, size = struct.unpack(">II", flbl.read(8)) + lbl = pyarray("b", flbl.read()) + flbl.close() + + fimg = open(fname_img, "rb") + magic_nr, size, rows, cols = struct.unpack(">IIII", fimg.read(16)) + img = pyarray("B", fimg.read()) + fimg.close() + + ind = [k for k in range(size) if lbl[k] in digits] + N = len(ind) + + images = zeros((N, rows, cols), dtype=uint8) + labels = zeros((N, 1), dtype=int8) + for i in range(len(ind)): + images[i] = array( + img[ind[i] * rows * cols : (ind[i] + 1) * rows * cols] + ).reshape((rows, cols)) + labels[i] = lbl[ind[i]] + + return images, labels + + X_train, y_train = load("train") + X_test, y_test = load("test") + + X_train = X_train.reshape(X_train.shape[0], 1, 28, 28).astype(np.float32) + X_test = X_test.reshape(X_test.shape[0], 1, 28, 28).astype(np.float32) + + return X_train, X_test, y_train, y_test + + +def load_nietzsche(): + text = open(get_filename("data/nietzsche.txt"), "rt").read().lower() + chars = set(list(text)) + char_indices = {ch: i for i, ch in enumerate(chars)} + indices_char = {i: ch for i, ch in enumerate(chars)} + + maxlen = 40 + step = 3 + sentences = [] + next_chars = [] + for i in range(0, len(text) - maxlen, step): + sentences.append(text[i : i + maxlen]) + next_chars.append(text[i + maxlen]) + + X = np.zeros((len(sentences), maxlen, len(chars)), dtype=np.bool) + y = np.zeros((len(sentences), len(chars)), dtype=np.bool) + for i, sentence in enumerate(sentences): + for t, char in enumerate(sentence): + X[i, t, char_indices[char]] = 1 + y[i, char_indices[next_chars[i]]] = 1 + return X, y, text, chars, char_indices, indices_char diff --git a/mla/datasets/data/mnist/t10k-images-idx3-ubyte b/mla/datasets/data/mnist/t10k-images-idx3-ubyte new file mode 100644 index 0000000..1170b2c Binary files /dev/null and b/mla/datasets/data/mnist/t10k-images-idx3-ubyte differ diff --git a/mla/datasets/data/mnist/t10k-labels-idx1-ubyte b/mla/datasets/data/mnist/t10k-labels-idx1-ubyte new file mode 100644 index 0000000..d1c3a97 Binary files /dev/null and b/mla/datasets/data/mnist/t10k-labels-idx1-ubyte differ diff --git a/mla/datasets/data/mnist/train-images-idx3-ubyte b/mla/datasets/data/mnist/train-images-idx3-ubyte new file mode 100644 index 0000000..bbce276 Binary files /dev/null and b/mla/datasets/data/mnist/train-images-idx3-ubyte differ diff --git a/mla/datasets/data/mnist/train-labels-idx1-ubyte b/mla/datasets/data/mnist/train-labels-idx1-ubyte new file mode 100644 index 0000000..d6b4c5d Binary files /dev/null and b/mla/datasets/data/mnist/train-labels-idx1-ubyte differ diff --git a/mla/datasets/data/nietzsche.txt b/mla/datasets/data/nietzsche.txt new file mode 100644 index 0000000..1d0bdb0 --- /dev/null +++ b/mla/datasets/data/nietzsche.txt @@ -0,0 +1,9935 @@ +PREFACE + + +SUPPOSING that Truth is a woman--what then? Is there not ground +for suspecting that all philosophers, in so far as they have been +dogmatists, have failed to understand women--that the terrible +seriousness and clumsy importunity with which they have usually paid +their addresses to Truth, have been unskilled and unseemly methods for +winning a woman? Certainly she has never allowed herself to be won; and +at present every kind of dogma stands with sad and discouraged mien--IF, +indeed, it stands at all! For there are scoffers who maintain that it +has fallen, that all dogma lies on the ground--nay more, that it is at +its last gasp. But to speak seriously, there are good grounds for hoping +that all dogmatizing in philosophy, whatever solemn, whatever conclusive +and decided airs it has assumed, may have been only a noble puerilism +and tyronism; and probably the time is at hand when it will be once +and again understood WHAT has actually sufficed for the basis of such +imposing and absolute philosophical edifices as the dogmatists have +hitherto reared: perhaps some popular superstition of immemorial time +(such as the soul-superstition, which, in the form of subject- and +ego-superstition, has not yet ceased doing mischief): perhaps some +play upon words, a deception on the part of grammar, or an +audacious generalization of very restricted, very personal, very +human--all-too-human facts. The philosophy of the dogmatists, it is to +be hoped, was only a promise for thousands of years afterwards, as was +astrology in still earlier times, in the service of which probably more +labour, gold, acuteness, and patience have been spent than on any +actual science hitherto: we owe to it, and to its "super-terrestrial" +pretensions in Asia and Egypt, the grand style of architecture. It seems +that in order to inscribe themselves upon the heart of humanity with +everlasting claims, all great things have first to wander about the +earth as enormous and awe-inspiring caricatures: dogmatic philosophy has +been a caricature of this kind--for instance, the Vedanta doctrine in +Asia, and Platonism in Europe. Let us not be ungrateful to it, although +it must certainly be confessed that the worst, the most tiresome, +and the most dangerous of errors hitherto has been a dogmatist +error--namely, Plato's invention of Pure Spirit and the Good in Itself. +But now when it has been surmounted, when Europe, rid of this nightmare, +can again draw breath freely and at least enjoy a healthier--sleep, +we, WHOSE DUTY IS WAKEFULNESS ITSELF, are the heirs of all the strength +which the struggle against this error has fostered. It amounted to +the very inversion of truth, and the denial of the PERSPECTIVE--the +fundamental condition--of life, to speak of Spirit and the Good as Plato +spoke of them; indeed one might ask, as a physician: "How did such a +malady attack that finest product of antiquity, Plato? Had the wicked +Socrates really corrupted him? Was Socrates after all a corrupter of +youths, and deserved his hemlock?" But the struggle against Plato, +or--to speak plainer, and for the "people"--the struggle against +the ecclesiastical oppression of millenniums of Christianity (FOR +CHRISTIANITY IS PLATONISM FOR THE "PEOPLE"), produced in Europe +a magnificent tension of soul, such as had not existed anywhere +previously; with such a tensely strained bow one can now aim at the +furthest goals. As a matter of fact, the European feels this tension as +a state of distress, and twice attempts have been made in grand style to +unbend the bow: once by means of Jesuitism, and the second time by means +of democratic enlightenment--which, with the aid of liberty of the press +and newspaper-reading, might, in fact, bring it about that the spirit +would not so easily find itself in "distress"! (The Germans invented +gunpowder--all credit to them! but they again made things square--they +invented printing.) But we, who are neither Jesuits, nor democrats, +nor even sufficiently Germans, we GOOD EUROPEANS, and free, VERY free +spirits--we have it still, all the distress of spirit and all the +tension of its bow! And perhaps also the arrow, the duty, and, who +knows? THE GOAL TO AIM AT.... + +Sils Maria Upper Engadine, JUNE, 1885. + + + + +CHAPTER I. PREJUDICES OF PHILOSOPHERS + + +1. The Will to Truth, which is to tempt us to many a hazardous +enterprise, the famous Truthfulness of which all philosophers have +hitherto spoken with respect, what questions has this Will to Truth not +laid before us! What strange, perplexing, questionable questions! It is +already a long story; yet it seems as if it were hardly commenced. Is +it any wonder if we at last grow distrustful, lose patience, and turn +impatiently away? That this Sphinx teaches us at last to ask questions +ourselves? WHO is it really that puts questions to us here? WHAT really +is this "Will to Truth" in us? In fact we made a long halt at the +question as to the origin of this Will--until at last we came to an +absolute standstill before a yet more fundamental question. We inquired +about the VALUE of this Will. Granted that we want the truth: WHY NOT +RATHER untruth? And uncertainty? Even ignorance? The problem of the +value of truth presented itself before us--or was it we who presented +ourselves before the problem? Which of us is the Oedipus here? Which +the Sphinx? It would seem to be a rendezvous of questions and notes of +interrogation. And could it be believed that it at last seems to us as +if the problem had never been propounded before, as if we were the first +to discern it, get a sight of it, and RISK RAISING it? For there is risk +in raising it, perhaps there is no greater risk. + +2. "HOW COULD anything originate out of its opposite? For example, truth +out of error? or the Will to Truth out of the will to deception? or the +generous deed out of selfishness? or the pure sun-bright vision of the +wise man out of covetousness? Such genesis is impossible; whoever dreams +of it is a fool, nay, worse than a fool; things of the highest +value must have a different origin, an origin of THEIR own--in this +transitory, seductive, illusory, paltry world, in this turmoil of +delusion and cupidity, they cannot have their source. But rather in +the lap of Being, in the intransitory, in the concealed God, in the +'Thing-in-itself--THERE must be their source, and nowhere else!"--This +mode of reasoning discloses the typical prejudice by which +metaphysicians of all times can be recognized, this mode of valuation +is at the back of all their logical procedure; through this "belief" of +theirs, they exert themselves for their "knowledge," for something that +is in the end solemnly christened "the Truth." The fundamental belief of +metaphysicians is THE BELIEF IN ANTITHESES OF VALUES. It never occurred +even to the wariest of them to doubt here on the very threshold (where +doubt, however, was most necessary); though they had made a solemn +vow, "DE OMNIBUS DUBITANDUM." For it may be doubted, firstly, whether +antitheses exist at all; and secondly, whether the popular valuations +and antitheses of value upon which metaphysicians have set their +seal, are not perhaps merely superficial estimates, merely provisional +perspectives, besides being probably made from some corner, perhaps from +below--"frog perspectives," as it were, to borrow an expression current +among painters. In spite of all the value which may belong to the true, +the positive, and the unselfish, it might be possible that a higher +and more fundamental value for life generally should be assigned to +pretence, to the will to delusion, to selfishness, and cupidity. It +might even be possible that WHAT constitutes the value of those good and +respected things, consists precisely in their being insidiously +related, knotted, and crocheted to these evil and apparently opposed +things--perhaps even in being essentially identical with them. Perhaps! +But who wishes to concern himself with such dangerous "Perhapses"! +For that investigation one must await the advent of a new order of +philosophers, such as will have other tastes and inclinations, the +reverse of those hitherto prevalent--philosophers of the dangerous +"Perhaps" in every sense of the term. And to speak in all seriousness, I +see such new philosophers beginning to appear. + +3. Having kept a sharp eye on philosophers, and having read between +their lines long enough, I now say to myself that the greater part of +conscious thinking must be counted among the instinctive functions, and +it is so even in the case of philosophical thinking; one has here to +learn anew, as one learned anew about heredity and "innateness." As +little as the act of birth comes into consideration in the whole process +and procedure of heredity, just as little is "being-conscious" OPPOSED +to the instinctive in any decisive sense; the greater part of the +conscious thinking of a philosopher is secretly influenced by his +instincts, and forced into definite channels. And behind all logic and +its seeming sovereignty of movement, there are valuations, or to speak +more plainly, physiological demands, for the maintenance of a definite +mode of life For example, that the certain is worth more than the +uncertain, that illusion is less valuable than "truth" such valuations, +in spite of their regulative importance for US, might notwithstanding be +only superficial valuations, special kinds of _niaiserie_, such as may +be necessary for the maintenance of beings such as ourselves. Supposing, +in effect, that man is not just the "measure of things." + +4. The falseness of an opinion is not for us any objection to it: it is +here, perhaps, that our new language sounds most strangely. The +question is, how far an opinion is life-furthering, life-preserving, +species-preserving, perhaps species-rearing, and we are fundamentally +inclined to maintain that the falsest opinions (to which the synthetic +judgments a priori belong), are the most indispensable to us, that +without a recognition of logical fictions, without a comparison of +reality with the purely IMAGINED world of the absolute and immutable, +without a constant counterfeiting of the world by means of numbers, +man could not live--that the renunciation of false opinions would be +a renunciation of life, a negation of life. TO RECOGNISE UNTRUTH AS A +CONDITION OF LIFE; that is certainly to impugn the traditional ideas of +value in a dangerous manner, and a philosophy which ventures to do so, +has thereby alone placed itself beyond good and evil. + +5. That which causes philosophers to be regarded half-distrustfully +and half-mockingly, is not the oft-repeated discovery how innocent they +are--how often and easily they make mistakes and lose their way, in +short, how childish and childlike they are,--but that there is not +enough honest dealing with them, whereas they all raise a loud and +virtuous outcry when the problem of truthfulness is even hinted at in +the remotest manner. They all pose as though their real opinions had +been discovered and attained through the self-evolving of a cold, pure, +divinely indifferent dialectic (in contrast to all sorts of mystics, +who, fairer and foolisher, talk of "inspiration"), whereas, in fact, a +prejudiced proposition, idea, or "suggestion," which is generally +their heart's desire abstracted and refined, is defended by them with +arguments sought out after the event. They are all advocates who do not +wish to be regarded as such, generally astute defenders, also, of their +prejudices, which they dub "truths,"--and VERY far from having the +conscience which bravely admits this to itself, very far from having +the good taste of the courage which goes so far as to let this be +understood, perhaps to warn friend or foe, or in cheerful confidence +and self-ridicule. The spectacle of the Tartuffery of old Kant, equally +stiff and decent, with which he entices us into the dialectic +by-ways that lead (more correctly mislead) to his "categorical +imperative"--makes us fastidious ones smile, we who find no small +amusement in spying out the subtle tricks of old moralists and ethical +preachers. Or, still more so, the hocus-pocus in mathematical form, by +means of which Spinoza has, as it were, clad his philosophy in mail and +mask--in fact, the "love of HIS wisdom," to translate the term fairly +and squarely--in order thereby to strike terror at once into the heart +of the assailant who should dare to cast a glance on that invincible +maiden, that Pallas Athene:--how much of personal timidity and +vulnerability does this masquerade of a sickly recluse betray! + +6. It has gradually become clear to me what every great philosophy up +till now has consisted of--namely, the confession of its originator, and +a species of involuntary and unconscious auto-biography; and moreover +that the moral (or immoral) purpose in every philosophy has constituted +the true vital germ out of which the entire plant has always grown. +Indeed, to understand how the abstrusest metaphysical assertions of a +philosopher have been arrived at, it is always well (and wise) to first +ask oneself: "What morality do they (or does he) aim at?" Accordingly, +I do not believe that an "impulse to knowledge" is the father of +philosophy; but that another impulse, here as elsewhere, has only made +use of knowledge (and mistaken knowledge!) as an instrument. But whoever +considers the fundamental impulses of man with a view to determining +how far they may have here acted as INSPIRING GENII (or as demons and +cobolds), will find that they have all practiced philosophy at one time +or another, and that each one of them would have been only too glad to +look upon itself as the ultimate end of existence and the legitimate +LORD over all the other impulses. For every impulse is imperious, and as +SUCH, attempts to philosophize. To be sure, in the case of scholars, in +the case of really scientific men, it may be otherwise--"better," if +you will; there there may really be such a thing as an "impulse to +knowledge," some kind of small, independent clock-work, which, when well +wound up, works away industriously to that end, WITHOUT the rest of +the scholarly impulses taking any material part therein. The actual +"interests" of the scholar, therefore, are generally in quite another +direction--in the family, perhaps, or in money-making, or in politics; +it is, in fact, almost indifferent at what point of research his little +machine is placed, and whether the hopeful young worker becomes a +good philologist, a mushroom specialist, or a chemist; he is not +CHARACTERISED by becoming this or that. In the philosopher, on the +contrary, there is absolutely nothing impersonal; and above all, +his morality furnishes a decided and decisive testimony as to WHO HE +IS,--that is to say, in what order the deepest impulses of his nature +stand to each other. + +7. How malicious philosophers can be! I know of nothing more stinging +than the joke Epicurus took the liberty of making on Plato and the +Platonists; he called them Dionysiokolakes. In its original sense, +and on the face of it, the word signifies "Flatterers of +Dionysius"--consequently, tyrants' accessories and lick-spittles; +besides this, however, it is as much as to say, "They are all ACTORS, +there is nothing genuine about them" (for Dionysiokolax was a popular +name for an actor). And the latter is really the malignant reproach that +Epicurus cast upon Plato: he was annoyed by the grandiose manner, the +mise en scene style of which Plato and his scholars were masters--of +which Epicurus was not a master! He, the old school-teacher of Samos, +who sat concealed in his little garden at Athens, and wrote three +hundred books, perhaps out of rage and ambitious envy of Plato, who +knows! Greece took a hundred years to find out who the garden-god +Epicurus really was. Did she ever find out? + +8. There is a point in every philosophy at which the "conviction" of +the philosopher appears on the scene; or, to put it in the words of an +ancient mystery: + +Adventavit asinus, Pulcher et fortissimus. + +9. You desire to LIVE "according to Nature"? Oh, you noble Stoics, what +fraud of words! Imagine to yourselves a being like Nature, boundlessly +extravagant, boundlessly indifferent, without purpose or consideration, +without pity or justice, at once fruitful and barren and uncertain: +imagine to yourselves INDIFFERENCE as a power--how COULD you live +in accordance with such indifference? To live--is not that just +endeavouring to be otherwise than this Nature? Is not living valuing, +preferring, being unjust, being limited, endeavouring to be different? +And granted that your imperative, "living according to Nature," means +actually the same as "living according to life"--how could you do +DIFFERENTLY? Why should you make a principle out of what you yourselves +are, and must be? In reality, however, it is quite otherwise with you: +while you pretend to read with rapture the canon of your law in Nature, +you want something quite the contrary, you extraordinary stage-players +and self-deluders! In your pride you wish to dictate your morals and +ideals to Nature, to Nature herself, and to incorporate them therein; +you insist that it shall be Nature "according to the Stoa," and would +like everything to be made after your own image, as a vast, eternal +glorification and generalism of Stoicism! With all your love for truth, +you have forced yourselves so long, so persistently, and with such +hypnotic rigidity to see Nature FALSELY, that is to say, Stoically, +that you are no longer able to see it otherwise--and to crown all, some +unfathomable superciliousness gives you the Bedlamite hope that +BECAUSE you are able to tyrannize over yourselves--Stoicism is +self-tyranny--Nature will also allow herself to be tyrannized over: is +not the Stoic a PART of Nature?... But this is an old and everlasting +story: what happened in old times with the Stoics still happens today, +as soon as ever a philosophy begins to believe in itself. It always +creates the world in its own image; it cannot do otherwise; philosophy +is this tyrannical impulse itself, the most spiritual Will to Power, the +will to "creation of the world," the will to the causa prima. + +10. The eagerness and subtlety, I should even say craftiness, with +which the problem of "the real and the apparent world" is dealt with at +present throughout Europe, furnishes food for thought and attention; and +he who hears only a "Will to Truth" in the background, and nothing else, +cannot certainly boast of the sharpest ears. In rare and isolated +cases, it may really have happened that such a Will to Truth--a certain +extravagant and adventurous pluck, a metaphysician's ambition of the +forlorn hope--has participated therein: that which in the end always +prefers a handful of "certainty" to a whole cartload of beautiful +possibilities; there may even be puritanical fanatics of conscience, +who prefer to put their last trust in a sure nothing, rather than in an +uncertain something. But that is Nihilism, and the sign of a despairing, +mortally wearied soul, notwithstanding the courageous bearing such a +virtue may display. It seems, however, to be otherwise with stronger +and livelier thinkers who are still eager for life. In that they side +AGAINST appearance, and speak superciliously of "perspective," in +that they rank the credibility of their own bodies about as low as the +credibility of the ocular evidence that "the earth stands still," and +thus, apparently, allowing with complacency their securest possession +to escape (for what does one at present believe in more firmly than +in one's body?),--who knows if they are not really trying to win back +something which was formerly an even securer possession, something +of the old domain of the faith of former times, perhaps the "immortal +soul," perhaps "the old God," in short, ideas by which they could live +better, that is to say, more vigorously and more joyously, than by +"modern ideas"? There is DISTRUST of these modern ideas in this mode +of looking at things, a disbelief in all that has been constructed +yesterday and today; there is perhaps some slight admixture of satiety +and scorn, which can no longer endure the BRIC-A-BRAC of ideas of the +most varied origin, such as so-called Positivism at present throws on +the market; a disgust of the more refined taste at the village-fair +motleyness and patchiness of all these reality-philosophasters, in whom +there is nothing either new or true, except this motleyness. Therein it +seems to me that we should agree with those skeptical anti-realists and +knowledge-microscopists of the present day; their instinct, which repels +them from MODERN reality, is unrefuted... what do their retrograde +by-paths concern us! The main thing about them is NOT that they wish +to go "back," but that they wish to get AWAY therefrom. A little MORE +strength, swing, courage, and artistic power, and they would be OFF--and +not back! + +11. It seems to me that there is everywhere an attempt at present to +divert attention from the actual influence which Kant exercised on +German philosophy, and especially to ignore prudently the value which +he set upon himself. Kant was first and foremost proud of his Table of +Categories; with it in his hand he said: "This is the most difficult +thing that could ever be undertaken on behalf of metaphysics." Let us +only understand this "could be"! He was proud of having DISCOVERED a +new faculty in man, the faculty of synthetic judgment a priori. Granting +that he deceived himself in this matter; the development and rapid +flourishing of German philosophy depended nevertheless on his pride, and +on the eager rivalry of the younger generation to discover if possible +something--at all events "new faculties"--of which to be still +prouder!--But let us reflect for a moment--it is high time to do so. +"How are synthetic judgments a priori POSSIBLE?" Kant asks himself--and +what is really his answer? "BY MEANS OF A MEANS (faculty)"--but +unfortunately not in five words, but so circumstantially, imposingly, +and with such display of German profundity and verbal flourishes, that +one altogether loses sight of the comical niaiserie allemande involved +in such an answer. People were beside themselves with delight over this +new faculty, and the jubilation reached its climax when Kant further +discovered a moral faculty in man--for at that time Germans were still +moral, not yet dabbling in the "Politics of hard fact." Then came +the honeymoon of German philosophy. All the young theologians of the +Tubingen institution went immediately into the groves--all seeking for +"faculties." And what did they not find--in that innocent, rich, and +still youthful period of the German spirit, to which Romanticism, the +malicious fairy, piped and sang, when one could not yet distinguish +between "finding" and "inventing"! Above all a faculty for the +"transcendental"; Schelling christened it, intellectual intuition, +and thereby gratified the most earnest longings of the naturally +pious-inclined Germans. One can do no greater wrong to the whole of +this exuberant and eccentric movement (which was really youthfulness, +notwithstanding that it disguised itself so boldly, in hoary and senile +conceptions), than to take it seriously, or even treat it with moral +indignation. Enough, however--the world grew older, and the dream +vanished. A time came when people rubbed their foreheads, and they still +rub them today. People had been dreaming, and first and foremost--old +Kant. "By means of a means (faculty)"--he had said, or at least meant to +say. But, is that--an answer? An explanation? Or is it not rather merely +a repetition of the question? How does opium induce sleep? "By means of +a means (faculty)," namely the virtus dormitiva, replies the doctor in +Moliere, + + Quia est in eo virtus dormitiva, + Cujus est natura sensus assoupire. + +But such replies belong to the realm of comedy, and it is high time +to replace the Kantian question, "How are synthetic judgments a PRIORI +possible?" by another question, "Why is belief in such judgments +necessary?"--in effect, it is high time that we should understand +that such judgments must be believed to be true, for the sake of the +preservation of creatures like ourselves; though they still might +naturally be false judgments! Or, more plainly spoken, and roughly and +readily--synthetic judgments a priori should not "be possible" at all; +we have no right to them; in our mouths they are nothing but false +judgments. Only, of course, the belief in their truth is necessary, as +plausible belief and ocular evidence belonging to the perspective view +of life. And finally, to call to mind the enormous influence which +"German philosophy"--I hope you understand its right to inverted commas +(goosefeet)?--has exercised throughout the whole of Europe, there is +no doubt that a certain VIRTUS DORMITIVA had a share in it; thanks to +German philosophy, it was a delight to the noble idlers, the virtuous, +the mystics, the artiste, the three-fourths Christians, and the +political obscurantists of all nations, to find an antidote to the still +overwhelming sensualism which overflowed from the last century into +this, in short--"sensus assoupire."... + +12. As regards materialistic atomism, it is one of the best-refuted +theories that have been advanced, and in Europe there is now perhaps +no one in the learned world so unscholarly as to attach serious +signification to it, except for convenient everyday use (as an +abbreviation of the means of expression)--thanks chiefly to the Pole +Boscovich: he and the Pole Copernicus have hitherto been the greatest +and most successful opponents of ocular evidence. For while Copernicus +has persuaded us to believe, contrary to all the senses, that the earth +does NOT stand fast, Boscovich has taught us to abjure the belief in the +last thing that "stood fast" of the earth--the belief in "substance," in +"matter," in the earth-residuum, and particle-atom: it is the greatest +triumph over the senses that has hitherto been gained on earth. One +must, however, go still further, and also declare war, relentless war +to the knife, against the "atomistic requirements" which still lead a +dangerous after-life in places where no one suspects them, like the more +celebrated "metaphysical requirements": one must also above all give +the finishing stroke to that other and more portentous atomism which +Christianity has taught best and longest, the SOUL-ATOMISM. Let it be +permitted to designate by this expression the belief which regards the +soul as something indestructible, eternal, indivisible, as a monad, +as an atomon: this belief ought to be expelled from science! Between +ourselves, it is not at all necessary to get rid of "the soul" thereby, +and thus renounce one of the oldest and most venerated hypotheses--as +happens frequently to the clumsiness of naturalists, who can hardly +touch on the soul without immediately losing it. But the way is open +for new acceptations and refinements of the soul-hypothesis; and such +conceptions as "mortal soul," and "soul of subjective multiplicity," +and "soul as social structure of the instincts and passions," want +henceforth to have legitimate rights in science. In that the NEW +psychologist is about to put an end to the superstitions which have +hitherto flourished with almost tropical luxuriance around the idea of +the soul, he is really, as it were, thrusting himself into a new desert +and a new distrust--it is possible that the older psychologists had a +merrier and more comfortable time of it; eventually, however, he finds +that precisely thereby he is also condemned to INVENT--and, who knows? +perhaps to DISCOVER the new. + +13. Psychologists should bethink themselves before putting down the +instinct of self-preservation as the cardinal instinct of an organic +being. A living thing seeks above all to DISCHARGE its strength--life +itself is WILL TO POWER; self-preservation is only one of the indirect +and most frequent RESULTS thereof. In short, here, as everywhere else, +let us beware of SUPERFLUOUS teleological principles!--one of which +is the instinct of self-preservation (we owe it to Spinoza's +inconsistency). It is thus, in effect, that method ordains, which must +be essentially economy of principles. + +14. It is perhaps just dawning on five or six minds that natural +philosophy is only a world-exposition and world-arrangement (according +to us, if I may say so!) and NOT a world-explanation; but in so far as +it is based on belief in the senses, it is regarded as more, and for a +long time to come must be regarded as more--namely, as an explanation. +It has eyes and fingers of its own, it has ocular evidence and +palpableness of its own: this operates fascinatingly, persuasively, and +CONVINCINGLY upon an age with fundamentally plebeian tastes--in fact, it +follows instinctively the canon of truth of eternal popular sensualism. +What is clear, what is "explained"? Only that which can be seen and +felt--one must pursue every problem thus far. Obversely, however, the +charm of the Platonic mode of thought, which was an ARISTOCRATIC mode, +consisted precisely in RESISTANCE to obvious sense-evidence--perhaps +among men who enjoyed even stronger and more fastidious senses than our +contemporaries, but who knew how to find a higher triumph in remaining +masters of them: and this by means of pale, cold, grey conceptional +networks which they threw over the motley whirl of the senses--the +mob of the senses, as Plato said. In this overcoming of the world, and +interpreting of the world in the manner of Plato, there was an ENJOYMENT +different from that which the physicists of today offer us--and likewise +the Darwinists and anti-teleologists among the physiological workers, +with their principle of the "smallest possible effort," and the greatest +possible blunder. "Where there is nothing more to see or to grasp, there +is also nothing more for men to do"--that is certainly an imperative +different from the Platonic one, but it may notwithstanding be the right +imperative for a hardy, laborious race of machinists and bridge-builders +of the future, who have nothing but ROUGH work to perform. + +15. To study physiology with a clear conscience, one must insist on +the fact that the sense-organs are not phenomena in the sense of the +idealistic philosophy; as such they certainly could not be causes! +Sensualism, therefore, at least as regulative hypothesis, if not as +heuristic principle. What? And others say even that the external world +is the work of our organs? But then our body, as a part of this external +world, would be the work of our organs! But then our organs themselves +would be the work of our organs! It seems to me that this is a +complete REDUCTIO AD ABSURDUM, if the conception CAUSA SUI is something +fundamentally absurd. Consequently, the external world is NOT the work +of our organs--? + +16. There are still harmless self-observers who believe that there are +"immediate certainties"; for instance, "I think," or as the superstition +of Schopenhauer puts it, "I will"; as though cognition here got hold +of its object purely and simply as "the thing in itself," without any +falsification taking place either on the part of the subject or the +object. I would repeat it, however, a hundred times, that "immediate +certainty," as well as "absolute knowledge" and the "thing in itself," +involve a CONTRADICTIO IN ADJECTO; we really ought to free ourselves +from the misleading significance of words! The people on their part may +think that cognition is knowing all about things, but the philosopher +must say to himself: "When I analyze the process that is expressed in +the sentence, 'I think,' I find a whole series of daring assertions, the +argumentative proof of which would be difficult, perhaps impossible: +for instance, that it is _I_ who think, that there must necessarily be +something that thinks, that thinking is an activity and operation on the +part of a being who is thought of as a cause, that there is an 'ego,' +and finally, that it is already determined what is to be designated by +thinking--that I KNOW what thinking is. For if I had not already decided +within myself what it is, by what standard could I determine whether +that which is just happening is not perhaps 'willing' or 'feeling'? In +short, the assertion 'I think,' assumes that I COMPARE my state at the +present moment with other states of myself which I know, in order to +determine what it is; on account of this retrospective connection with +further 'knowledge,' it has, at any rate, no immediate certainty for +me."--In place of the "immediate certainty" in which the people may +believe in the special case, the philosopher thus finds a series of +metaphysical questions presented to him, veritable conscience questions +of the intellect, to wit: "Whence did I get the notion of 'thinking'? +Why do I believe in cause and effect? What gives me the right to speak +of an 'ego,' and even of an 'ego' as cause, and finally of an 'ego' +as cause of thought?" He who ventures to answer these metaphysical +questions at once by an appeal to a sort of INTUITIVE perception, like +the person who says, "I think, and know that this, at least, is +true, actual, and certain"--will encounter a smile and two notes of +interrogation in a philosopher nowadays. "Sir," the philosopher will +perhaps give him to understand, "it is improbable that you are not +mistaken, but why should it be the truth?" + +17. With regard to the superstitions of logicians, I shall never tire +of emphasizing a small, terse fact, which is unwillingly recognized by +these credulous minds--namely, that a thought comes when "it" wishes, +and not when "I" wish; so that it is a PERVERSION of the facts of the +case to say that the subject "I" is the condition of the predicate +"think." ONE thinks; but that this "one" is precisely the famous old +"ego," is, to put it mildly, only a supposition, an assertion, and +assuredly not an "immediate certainty." After all, one has even gone too +far with this "one thinks"--even the "one" contains an INTERPRETATION of +the process, and does not belong to the process itself. One infers here +according to the usual grammatical formula--"To think is an activity; +every activity requires an agency that is active; consequently"... It +was pretty much on the same lines that the older atomism sought, besides +the operating "power," the material particle wherein it resides and out +of which it operates--the atom. More rigorous minds, however, learnt at +last to get along without this "earth-residuum," and perhaps some day we +shall accustom ourselves, even from the logician's point of view, to +get along without the little "one" (to which the worthy old "ego" has +refined itself). + +18. It is certainly not the least charm of a theory that it is +refutable; it is precisely thereby that it attracts the more subtle +minds. It seems that the hundred-times-refuted theory of the "free will" +owes its persistence to this charm alone; some one is always appearing +who feels himself strong enough to refute it. + +19. Philosophers are accustomed to speak of the will as though it were +the best-known thing in the world; indeed, Schopenhauer has given us +to understand that the will alone is really known to us, absolutely and +completely known, without deduction or addition. But it again and +again seems to me that in this case Schopenhauer also only did what +philosophers are in the habit of doing--he seems to have adopted a +POPULAR PREJUDICE and exaggerated it. Willing seems to me to be above +all something COMPLICATED, something that is a unity only in name--and +it is precisely in a name that popular prejudice lurks, which has got +the mastery over the inadequate precautions of philosophers in all ages. +So let us for once be more cautious, let us be "unphilosophical": let +us say that in all willing there is firstly a plurality of sensations, +namely, the sensation of the condition "AWAY FROM WHICH we go," the +sensation of the condition "TOWARDS WHICH we go," the sensation of this +"FROM" and "TOWARDS" itself, and then besides, an accompanying muscular +sensation, which, even without our putting in motion "arms and legs," +commences its action by force of habit, directly we "will" anything. +Therefore, just as sensations (and indeed many kinds of sensations) are +to be recognized as ingredients of the will, so, in the second place, +thinking is also to be recognized; in every act of the will there is +a ruling thought;--and let us not imagine it possible to sever this +thought from the "willing," as if the will would then remain over! +In the third place, the will is not only a complex of sensation and +thinking, but it is above all an EMOTION, and in fact the emotion of the +command. That which is termed "freedom of the will" is essentially the +emotion of supremacy in respect to him who must obey: "I am free, 'he' +must obey"--this consciousness is inherent in every will; and equally +so the straining of the attention, the straight look which fixes itself +exclusively on one thing, the unconditional judgment that "this and +nothing else is necessary now," the inward certainty that obedience +will be rendered--and whatever else pertains to the position of the +commander. A man who WILLS commands something within himself which +renders obedience, or which he believes renders obedience. But now let +us notice what is the strangest thing about the will,--this affair so +extremely complex, for which the people have only one name. Inasmuch as +in the given circumstances we are at the same time the commanding AND +the obeying parties, and as the obeying party we know the sensations of +constraint, impulsion, pressure, resistance, and motion, which usually +commence immediately after the act of will; inasmuch as, on the other +hand, we are accustomed to disregard this duality, and to deceive +ourselves about it by means of the synthetic term "I": a whole series +of erroneous conclusions, and consequently of false judgments about the +will itself, has become attached to the act of willing--to such a degree +that he who wills believes firmly that willing SUFFICES for action. +Since in the majority of cases there has only been exercise of will +when the effect of the command--consequently obedience, and therefore +action--was to be EXPECTED, the APPEARANCE has translated itself into +the sentiment, as if there were a NECESSITY OF EFFECT; in a word, he who +wills believes with a fair amount of certainty that will and action are +somehow one; he ascribes the success, the carrying out of the willing, +to the will itself, and thereby enjoys an increase of the sensation +of power which accompanies all success. "Freedom of Will"--that is the +expression for the complex state of delight of the person exercising +volition, who commands and at the same time identifies himself with +the executor of the order--who, as such, enjoys also the triumph over +obstacles, but thinks within himself that it was really his own will +that overcame them. In this way the person exercising volition adds the +feelings of delight of his successful executive instruments, the useful +"underwills" or under-souls--indeed, our body is but a social structure +composed of many souls--to his feelings of delight as commander. L'EFFET +C'EST MOI. what happens here is what happens in every well-constructed +and happy commonwealth, namely, that the governing class identifies +itself with the successes of the commonwealth. In all willing it is +absolutely a question of commanding and obeying, on the basis, as +already said, of a social structure composed of many "souls", on which +account a philosopher should claim the right to include willing-as-such +within the sphere of morals--regarded as the doctrine of the relations +of supremacy under which the phenomenon of "life" manifests itself. + +20. That the separate philosophical ideas are not anything optional or +autonomously evolving, but grow up in connection and relationship with +each other, that, however suddenly and arbitrarily they seem to appear +in the history of thought, they nevertheless belong just as much to +a system as the collective members of the fauna of a Continent--is +betrayed in the end by the circumstance: how unfailingly the most +diverse philosophers always fill in again a definite fundamental scheme +of POSSIBLE philosophies. Under an invisible spell, they always revolve +once more in the same orbit, however independent of each other they +may feel themselves with their critical or systematic wills, something +within them leads them, something impels them in definite order the +one after the other--to wit, the innate methodology and relationship +of their ideas. Their thinking is, in fact, far less a discovery than a +re-recognizing, a remembering, a return and a home-coming to a far-off, +ancient common-household of the soul, out of which those ideas formerly +grew: philosophizing is so far a kind of atavism of the highest order. +The wonderful family resemblance of all Indian, Greek, and German +philosophizing is easily enough explained. In fact, where there is +affinity of language, owing to the common philosophy of grammar--I mean +owing to the unconscious domination and guidance of similar grammatical +functions--it cannot but be that everything is prepared at the outset +for a similar development and succession of philosophical systems, +just as the way seems barred against certain other possibilities of +world-interpretation. It is highly probable that philosophers within the +domain of the Ural-Altaic languages (where the conception of the subject +is least developed) look otherwise "into the world," and will be +found on paths of thought different from those of the Indo-Germans and +Mussulmans, the spell of certain grammatical functions is ultimately +also the spell of PHYSIOLOGICAL valuations and racial conditions.--So +much by way of rejecting Locke's superficiality with regard to the +origin of ideas. + +21. The CAUSA SUI is the best self-contradiction that has yet been +conceived, it is a sort of logical violation and unnaturalness; but the +extravagant pride of man has managed to entangle itself profoundly and +frightfully with this very folly. The desire for "freedom of will" +in the superlative, metaphysical sense, such as still holds sway, +unfortunately, in the minds of the half-educated, the desire to bear +the entire and ultimate responsibility for one's actions oneself, and +to absolve God, the world, ancestors, chance, and society therefrom, +involves nothing less than to be precisely this CAUSA SUI, and, with +more than Munchausen daring, to pull oneself up into existence by the +hair, out of the slough of nothingness. If any one should find out in +this manner the crass stupidity of the celebrated conception of "free +will" and put it out of his head altogether, I beg of him to carry +his "enlightenment" a step further, and also put out of his head the +contrary of this monstrous conception of "free will": I mean "non-free +will," which is tantamount to a misuse of cause and effect. One +should not wrongly MATERIALISE "cause" and "effect," as the natural +philosophers do (and whoever like them naturalize in thinking at +present), according to the prevailing mechanical doltishness which makes +the cause press and push until it "effects" its end; one should use +"cause" and "effect" only as pure CONCEPTIONS, that is to say, as +conventional fictions for the purpose of designation and mutual +understanding,--NOT for explanation. In "being-in-itself" there is +nothing of "casual-connection," of "necessity," or of "psychological +non-freedom"; there the effect does NOT follow the cause, there "law" +does not obtain. It is WE alone who have devised cause, sequence, +reciprocity, relativity, constraint, number, law, freedom, motive, +and purpose; and when we interpret and intermix this symbol-world, +as "being-in-itself," with things, we act once more as we have always +acted--MYTHOLOGICALLY. The "non-free will" is mythology; in real life +it is only a question of STRONG and WEAK wills.--It is almost always +a symptom of what is lacking in himself, when a thinker, in every +"causal-connection" and "psychological necessity," manifests something +of compulsion, indigence, obsequiousness, oppression, and non-freedom; +it is suspicious to have such feelings--the person betrays himself. And +in general, if I have observed correctly, the "non-freedom of the will" +is regarded as a problem from two entirely opposite standpoints, but +always in a profoundly PERSONAL manner: some will not give up their +"responsibility," their belief in THEMSELVES, the personal right to +THEIR merits, at any price (the vain races belong to this class); others +on the contrary, do not wish to be answerable for anything, or blamed +for anything, and owing to an inward self-contempt, seek to GET OUT OF +THE BUSINESS, no matter how. The latter, when they write books, are +in the habit at present of taking the side of criminals; a sort of +socialistic sympathy is their favourite disguise. And as a matter of +fact, the fatalism of the weak-willed embellishes itself surprisingly +when it can pose as "la religion de la souffrance humaine"; that is ITS +"good taste." + +22. Let me be pardoned, as an old philologist who cannot desist from +the mischief of putting his finger on bad modes of interpretation, but +"Nature's conformity to law," of which you physicists talk so proudly, +as though--why, it exists only owing to your interpretation and bad +"philology." It is no matter of fact, no "text," but rather just a +naively humanitarian adjustment and perversion of meaning, with which +you make abundant concessions to the democratic instincts of the modern +soul! "Everywhere equality before the law--Nature is not different in +that respect, nor better than we": a fine instance of secret motive, +in which the vulgar antagonism to everything privileged and +autocratic--likewise a second and more refined atheism--is once more +disguised. "Ni dieu, ni maitre"--that, also, is what you want; and +therefore "Cheers for natural law!"--is it not so? But, as has been +said, that is interpretation, not text; and somebody might come along, +who, with opposite intentions and modes of interpretation, could read +out of the same "Nature," and with regard to the same phenomena, just +the tyrannically inconsiderate and relentless enforcement of the claims +of power--an interpreter who should so place the unexceptionalness and +unconditionalness of all "Will to Power" before your eyes, that almost +every word, and the word "tyranny" itself, would eventually seem +unsuitable, or like a weakening and softening metaphor--as being too +human; and who should, nevertheless, end by asserting the same about +this world as you do, namely, that it has a "necessary" and "calculable" +course, NOT, however, because laws obtain in it, but because they are +absolutely LACKING, and every power effects its ultimate consequences +every moment. Granted that this also is only interpretation--and you +will be eager enough to make this objection?--well, so much the better. + +23. All psychology hitherto has run aground on moral prejudices and +timidities, it has not dared to launch out into the depths. In so far +as it is allowable to recognize in that which has hitherto been written, +evidence of that which has hitherto been kept silent, it seems as if +nobody had yet harboured the notion of psychology as the Morphology +and DEVELOPMENT-DOCTRINE OF THE WILL TO POWER, as I conceive of it. +The power of moral prejudices has penetrated deeply into the most +intellectual world, the world apparently most indifferent and +unprejudiced, and has obviously operated in an injurious, obstructive, +blinding, and distorting manner. A proper physio-psychology has to +contend with unconscious antagonism in the heart of the investigator, +it has "the heart" against it even a doctrine of the reciprocal +conditionalness of the "good" and the "bad" impulses, causes (as +refined immorality) distress and aversion in a still strong and manly +conscience--still more so, a doctrine of the derivation of all good +impulses from bad ones. If, however, a person should regard even +the emotions of hatred, envy, covetousness, and imperiousness +as life-conditioning emotions, as factors which must be present, +fundamentally and essentially, in the general economy of life (which +must, therefore, be further developed if life is to be further +developed), he will suffer from such a view of things as from +sea-sickness. And yet this hypothesis is far from being the strangest +and most painful in this immense and almost new domain of dangerous +knowledge, and there are in fact a hundred good reasons why every one +should keep away from it who CAN do so! On the other hand, if one has +once drifted hither with one's bark, well! very good! now let us set our +teeth firmly! let us open our eyes and keep our hand fast on the helm! +We sail away right OVER morality, we crush out, we destroy perhaps the +remains of our own morality by daring to make our voyage thither--but +what do WE matter. Never yet did a PROFOUNDER world of insight reveal +itself to daring travelers and adventurers, and the psychologist who +thus "makes a sacrifice"--it is not the sacrifizio dell' intelletto, +on the contrary!--will at least be entitled to demand in return that +psychology shall once more be recognized as the queen of the sciences, +for whose service and equipment the other sciences exist. For psychology +is once more the path to the fundamental problems. + + + +CHAPTER II. THE FREE SPIRIT + + +24. O sancta simplicitiatas! In what strange simplification and +falsification man lives! One can never cease wondering when once one has +got eyes for beholding this marvel! How we have made everything around +us clear and free and easy and simple! how we have been able to give +our senses a passport to everything superficial, our thoughts a godlike +desire for wanton pranks and wrong inferences!--how from the beginning, +we have contrived to retain our ignorance in order to enjoy an almost +inconceivable freedom, thoughtlessness, imprudence, heartiness, +and gaiety--in order to enjoy life! And only on this solidified, +granite-like foundation of ignorance could knowledge rear itself +hitherto, the will to knowledge on the foundation of a far more powerful +will, the will to ignorance, to the uncertain, to the untrue! Not as +its opposite, but--as its refinement! It is to be hoped, indeed, that +LANGUAGE, here as elsewhere, will not get over its awkwardness, and that +it will continue to talk of opposites where there are only degrees +and many refinements of gradation; it is equally to be hoped that the +incarnated Tartuffery of morals, which now belongs to our unconquerable +"flesh and blood," will turn the words round in the mouths of us +discerning ones. Here and there we understand it, and laugh at the way +in which precisely the best knowledge seeks most to retain us in this +SIMPLIFIED, thoroughly artificial, suitably imagined, and suitably +falsified world: at the way in which, whether it will or not, it loves +error, because, as living itself, it loves life! + +25. After such a cheerful commencement, a serious word would fain be +heard; it appeals to the most serious minds. Take care, ye philosophers +and friends of knowledge, and beware of martyrdom! Of suffering "for the +truth's sake"! even in your own defense! It spoils all the innocence +and fine neutrality of your conscience; it makes you headstrong against +objections and red rags; it stupefies, animalizes, and brutalizes, when +in the struggle with danger, slander, suspicion, expulsion, and even +worse consequences of enmity, ye have at last to play your last card +as protectors of truth upon earth--as though "the Truth" were such an +innocent and incompetent creature as to require protectors! and you of +all people, ye knights of the sorrowful countenance, Messrs Loafers and +Cobweb-spinners of the spirit! Finally, ye know sufficiently well that +it cannot be of any consequence if YE just carry your point; ye know +that hitherto no philosopher has carried his point, and that there might +be a more laudable truthfulness in every little interrogative mark +which you place after your special words and favourite doctrines (and +occasionally after yourselves) than in all the solemn pantomime and +trumping games before accusers and law-courts! Rather go out of the way! +Flee into concealment! And have your masks and your ruses, that ye may +be mistaken for what you are, or somewhat feared! And pray, don't forget +the garden, the garden with golden trellis-work! And have people around +you who are as a garden--or as music on the waters at eventide, when +already the day becomes a memory. Choose the GOOD solitude, the free, +wanton, lightsome solitude, which also gives you the right still to +remain good in any sense whatsoever! How poisonous, how crafty, how bad, +does every long war make one, which cannot be waged openly by means +of force! How PERSONAL does a long fear make one, a long watching +of enemies, of possible enemies! These pariahs of society, these +long-pursued, badly-persecuted ones--also the compulsory recluses, the +Spinozas or Giordano Brunos--always become in the end, even under the +most intellectual masquerade, and perhaps without being themselves aware +of it, refined vengeance-seekers and poison-Brewers (just lay bare +the foundation of Spinoza's ethics and theology!), not to speak of +the stupidity of moral indignation, which is the unfailing sign in a +philosopher that the sense of philosophical humour has left him. The +martyrdom of the philosopher, his "sacrifice for the sake of truth," +forces into the light whatever of the agitator and actor lurks in him; +and if one has hitherto contemplated him only with artistic curiosity, +with regard to many a philosopher it is easy to understand the dangerous +desire to see him also in his deterioration (deteriorated into a +"martyr," into a stage-and-tribune-bawler). Only, that it is necessary +with such a desire to be clear WHAT spectacle one will see in any +case--merely a satyric play, merely an epilogue farce, merely the +continued proof that the long, real tragedy IS AT AN END, supposing that +every philosophy has been a long tragedy in its origin. + +26. Every select man strives instinctively for a citadel and a privacy, +where he is FREE from the crowd, the many, the majority--where he may +forget "men who are the rule," as their exception;--exclusive only of +the case in which he is pushed straight to such men by a still stronger +instinct, as a discerner in the great and exceptional sense. Whoever, in +intercourse with men, does not occasionally glisten in all the green +and grey colours of distress, owing to disgust, satiety, sympathy, +gloominess, and solitariness, is assuredly not a man of elevated tastes; +supposing, however, that he does not voluntarily take all this burden +and disgust upon himself, that he persistently avoids it, and remains, +as I said, quietly and proudly hidden in his citadel, one thing is then +certain: he was not made, he was not predestined for knowledge. For as +such, he would one day have to say to himself: "The devil take my good +taste! but 'the rule' is more interesting than the exception--than +myself, the exception!" And he would go DOWN, and above all, he would +go "inside." The long and serious study of the AVERAGE man--and +consequently much disguise, self-overcoming, familiarity, and bad +intercourse (all intercourse is bad intercourse except with one's +equals):--that constitutes a necessary part of the life-history of every +philosopher; perhaps the most disagreeable, odious, and disappointing +part. If he is fortunate, however, as a favourite child of knowledge +should be, he will meet with suitable auxiliaries who will shorten and +lighten his task; I mean so-called cynics, those who simply recognize +the animal, the commonplace and "the rule" in themselves, and at the +same time have so much spirituality and ticklishness as to make them +talk of themselves and their like BEFORE WITNESSES--sometimes they +wallow, even in books, as on their own dung-hill. Cynicism is the only +form in which base souls approach what is called honesty; and the +higher man must open his ears to all the coarser or finer cynicism, and +congratulate himself when the clown becomes shameless right before +him, or the scientific satyr speaks out. There are even cases where +enchantment mixes with the disgust--namely, where by a freak of nature, +genius is bound to some such indiscreet billy-goat and ape, as in the +case of the Abbe Galiani, the profoundest, acutest, and perhaps also +filthiest man of his century--he was far profounder than Voltaire, and +consequently also, a good deal more silent. It happens more frequently, +as has been hinted, that a scientific head is placed on an ape's body, a +fine exceptional understanding in a base soul, an occurrence by no means +rare, especially among doctors and moral physiologists. And whenever +anyone speaks without bitterness, or rather quite innocently, of man +as a belly with two requirements, and a head with one; whenever any one +sees, seeks, and WANTS to see only hunger, sexual instinct, and vanity +as the real and only motives of human actions; in short, when any one +speaks "badly"--and not even "ill"--of man, then ought the lover of +knowledge to hearken attentively and diligently; he ought, in general, +to have an open ear wherever there is talk without indignation. For the +indignant man, and he who perpetually tears and lacerates himself with +his own teeth (or, in place of himself, the world, God, or society), +may indeed, morally speaking, stand higher than the laughing and +self-satisfied satyr, but in every other sense he is the more ordinary, +more indifferent, and less instructive case. And no one is such a LIAR +as the indignant man. + +27. It is difficult to be understood, especially when one thinks and +lives gangasrotogati [Footnote: Like the river Ganges: presto.] among +those only who think and live otherwise--namely, kurmagati [Footnote: +Like the tortoise: lento.], or at best "froglike," mandeikagati +[Footnote: Like the frog: staccato.] (I do everything to be "difficultly +understood" myself!)--and one should be heartily grateful for the +good will to some refinement of interpretation. As regards "the good +friends," however, who are always too easy-going, and think that as +friends they have a right to ease, one does well at the very first to +grant them a play-ground and romping-place for misunderstanding--one can +thus laugh still; or get rid of them altogether, these good friends--and +laugh then also! + +28. What is most difficult to render from one language into another +is the TEMPO of its style, which has its basis in the character of the +race, or to speak more physiologically, in the average TEMPO of the +assimilation of its nutriment. There are honestly meant translations, +which, as involuntary vulgarizations, are almost falsifications of the +original, merely because its lively and merry TEMPO (which overleaps and +obviates all dangers in word and expression) could not also be +rendered. A German is almost incapacitated for PRESTO in his language; +consequently also, as may be reasonably inferred, for many of the most +delightful and daring NUANCES of free, free-spirited thought. And just +as the buffoon and satyr are foreign to him in body and conscience, +so Aristophanes and Petronius are untranslatable for him. Everything +ponderous, viscous, and pompously clumsy, all long-winded and wearying +species of style, are developed in profuse variety among Germans--pardon +me for stating the fact that even Goethe's prose, in its mixture of +stiffness and elegance, is no exception, as a reflection of the "good +old time" to which it belongs, and as an expression of German taste at a +time when there was still a "German taste," which was a rococo-taste +in moribus et artibus. Lessing is an exception, owing to his histrionic +nature, which understood much, and was versed in many things; he who was +not the translator of Bayle to no purpose, who took refuge willingly in +the shadow of Diderot and Voltaire, and still more willingly among the +Roman comedy-writers--Lessing loved also free-spiritism in the TEMPO, +and flight out of Germany. But how could the German language, even +in the prose of Lessing, imitate the TEMPO of Machiavelli, who in his +"Principe" makes us breathe the dry, fine air of Florence, and cannot +help presenting the most serious events in a boisterous allegrissimo, +perhaps not without a malicious artistic sense of the contrast he +ventures to present--long, heavy, difficult, dangerous thoughts, and +a TEMPO of the gallop, and of the best, wantonest humour? Finally, who +would venture on a German translation of Petronius, who, more than any +great musician hitherto, was a master of PRESTO in invention, ideas, and +words? What matter in the end about the swamps of the sick, evil world, +or of the "ancient world," when like him, one has the feet of a wind, +the rush, the breath, the emancipating scorn of a wind, which makes +everything healthy, by making everything RUN! And with regard to +Aristophanes--that transfiguring, complementary genius, for whose +sake one PARDONS all Hellenism for having existed, provided one has +understood in its full profundity ALL that there requires pardon and +transfiguration; there is nothing that has caused me to meditate more on +PLATO'S secrecy and sphinx-like nature, than the happily preserved petit +fait that under the pillow of his death-bed there was found no +"Bible," nor anything Egyptian, Pythagorean, or Platonic--but a book of +Aristophanes. How could even Plato have endured life--a Greek life which +he repudiated--without an Aristophanes! + +29. It is the business of the very few to be independent; it is a +privilege of the strong. And whoever attempts it, even with the best +right, but without being OBLIGED to do so, proves that he is probably +not only strong, but also daring beyond measure. He enters into a +labyrinth, he multiplies a thousandfold the dangers which life in itself +already brings with it; not the least of which is that no one can see +how and where he loses his way, becomes isolated, and is torn piecemeal +by some minotaur of conscience. Supposing such a one comes to grief, it +is so far from the comprehension of men that they neither feel it, nor +sympathize with it. And he cannot any longer go back! He cannot even go +back again to the sympathy of men! + +30. Our deepest insights must--and should--appear as follies, and under +certain circumstances as crimes, when they come unauthorizedly to +the ears of those who are not disposed and predestined for them. The +exoteric and the esoteric, as they were formerly distinguished by +philosophers--among the Indians, as among the Greeks, Persians, and +Mussulmans, in short, wherever people believed in gradations of rank and +NOT in equality and equal rights--are not so much in contradistinction +to one another in respect to the exoteric class, standing without, and +viewing, estimating, measuring, and judging from the outside, and not +from the inside; the more essential distinction is that the class in +question views things from below upwards--while the esoteric class views +things FROM ABOVE DOWNWARDS. There are heights of the soul from which +tragedy itself no longer appears to operate tragically; and if all the +woe in the world were taken together, who would dare to decide whether +the sight of it would NECESSARILY seduce and constrain to sympathy, and +thus to a doubling of the woe?... That which serves the higher class of +men for nourishment or refreshment, must be almost poison to an entirely +different and lower order of human beings. The virtues of the common +man would perhaps mean vice and weakness in a philosopher; it might be +possible for a highly developed man, supposing him to degenerate and go +to ruin, to acquire qualities thereby alone, for the sake of which he +would have to be honoured as a saint in the lower world into which he +had sunk. There are books which have an inverse value for the soul and +the health according as the inferior soul and the lower vitality, or the +higher and more powerful, make use of them. In the former case they are +dangerous, disturbing, unsettling books, in the latter case they are +herald-calls which summon the bravest to THEIR bravery. Books for the +general reader are always ill-smelling books, the odour of paltry people +clings to them. Where the populace eat and drink, and even where they +reverence, it is accustomed to stink. One should not go into churches if +one wishes to breathe PURE air. + +31. In our youthful years we still venerate and despise without the art +of NUANCE, which is the best gain of life, and we have rightly to do +hard penance for having fallen upon men and things with Yea and Nay. +Everything is so arranged that the worst of all tastes, THE TASTE FOR +THE UNCONDITIONAL, is cruelly befooled and abused, until a man learns +to introduce a little art into his sentiments, and prefers to try +conclusions with the artificial, as do the real artists of life. The +angry and reverent spirit peculiar to youth appears to allow itself no +peace, until it has suitably falsified men and things, to be able +to vent its passion upon them: youth in itself even, is something +falsifying and deceptive. Later on, when the young soul, tortured by +continual disillusions, finally turns suspiciously against itself--still +ardent and savage even in its suspicion and remorse of conscience: how +it upbraids itself, how impatiently it tears itself, how it revenges +itself for its long self-blinding, as though it had been a voluntary +blindness! In this transition one punishes oneself by distrust of one's +sentiments; one tortures one's enthusiasm with doubt, one feels even the +good conscience to be a danger, as if it were the self-concealment and +lassitude of a more refined uprightness; and above all, one espouses +upon principle the cause AGAINST "youth."--A decade later, and one +comprehends that all this was also still--youth! + +32. Throughout the longest period of human history--one calls it the +prehistoric period--the value or non-value of an action was inferred +from its CONSEQUENCES; the action in itself was not taken into +consideration, any more than its origin; but pretty much as in China at +present, where the distinction or disgrace of a child redounds to +its parents, the retro-operating power of success or failure was what +induced men to think well or ill of an action. Let us call this period +the PRE-MORAL period of mankind; the imperative, "Know thyself!" was +then still unknown.--In the last ten thousand years, on the other hand, +on certain large portions of the earth, one has gradually got so far, +that one no longer lets the consequences of an action, but its origin, +decide with regard to its worth: a great achievement as a whole, an +important refinement of vision and of criterion, the unconscious effect +of the supremacy of aristocratic values and of the belief in "origin," +the mark of a period which may be designated in the narrower sense as +the MORAL one: the first attempt at self-knowledge is thereby +made. Instead of the consequences, the origin--what an inversion +of perspective! And assuredly an inversion effected only after long +struggle and wavering! To be sure, an ominous new superstition, a +peculiar narrowness of interpretation, attained supremacy precisely +thereby: the origin of an action was interpreted in the most definite +sense possible, as origin out of an INTENTION; people were agreed in the +belief that the value of an action lay in the value of its intention. +The intention as the sole origin and antecedent history of an action: +under the influence of this prejudice moral praise and blame have been +bestowed, and men have judged and even philosophized almost up to the +present day.--Is it not possible, however, that the necessity may now +have arisen of again making up our minds with regard to the reversing +and fundamental shifting of values, owing to a new self-consciousness +and acuteness in man--is it not possible that we may be standing on +the threshold of a period which to begin with, would be distinguished +negatively as ULTRA-MORAL: nowadays when, at least among us immoralists, +the suspicion arises that the decisive value of an action lies precisely +in that which is NOT INTENTIONAL, and that all its intentionalness, all +that is seen, sensible, or "sensed" in it, belongs to its surface or +skin--which, like every skin, betrays something, but CONCEALS still +more? In short, we believe that the intention is only a sign or symptom, +which first requires an explanation--a sign, moreover, which has too +many interpretations, and consequently hardly any meaning in itself +alone: that morality, in the sense in which it has been understood +hitherto, as intention-morality, has been a prejudice, perhaps a +prematureness or preliminariness, probably something of the same rank +as astrology and alchemy, but in any case something which must be +surmounted. The surmounting of morality, in a certain sense even the +self-mounting of morality--let that be the name for the long-secret +labour which has been reserved for the most refined, the most upright, +and also the most wicked consciences of today, as the living touchstones +of the soul. + +33. It cannot be helped: the sentiment of surrender, of sacrifice for +one's neighbour, and all self-renunciation-morality, must be mercilessly +called to account, and brought to judgment; just as the aesthetics +of "disinterested contemplation," under which the emasculation of art +nowadays seeks insidiously enough to create itself a good conscience. +There is far too much witchery and sugar in the sentiments "for others" +and "NOT for myself," for one not needing to be doubly distrustful here, +and for one asking promptly: "Are they not perhaps--DECEPTIONS?"--That +they PLEASE--him who has them, and him who enjoys their fruit, and also +the mere spectator--that is still no argument in their FAVOUR, but just +calls for caution. Let us therefore be cautious! + +34. At whatever standpoint of philosophy one may place oneself nowadays, +seen from every position, the ERRONEOUSNESS of the world in which we +think we live is the surest and most certain thing our eyes can light +upon: we find proof after proof thereof, which would fain allure us into +surmises concerning a deceptive principle in the "nature of things." +He, however, who makes thinking itself, and consequently "the spirit," +responsible for the falseness of the world--an honourable exit, which +every conscious or unconscious advocatus dei avails himself of--he +who regards this world, including space, time, form, and movement, as +falsely DEDUCED, would have at least good reason in the end to become +distrustful also of all thinking; has it not hitherto been playing upon +us the worst of scurvy tricks? and what guarantee would it give that +it would not continue to do what it has always been doing? In all +seriousness, the innocence of thinkers has something touching and +respect-inspiring in it, which even nowadays permits them to wait upon +consciousness with the request that it will give them HONEST answers: +for example, whether it be "real" or not, and why it keeps the outer +world so resolutely at a distance, and other questions of the same +description. The belief in "immediate certainties" is a MORAL NAIVETE +which does honour to us philosophers; but--we have now to cease being +"MERELY moral" men! Apart from morality, such belief is a folly which +does little honour to us! If in middle-class life an ever-ready distrust +is regarded as the sign of a "bad character," and consequently as an +imprudence, here among us, beyond the middle-class world and its Yeas +and Nays, what should prevent our being imprudent and saying: the +philosopher has at length a RIGHT to "bad character," as the being who +has hitherto been most befooled on earth--he is now under OBLIGATION +to distrustfulness, to the wickedest squinting out of every abyss of +suspicion.--Forgive me the joke of this gloomy grimace and turn of +expression; for I myself have long ago learned to think and estimate +differently with regard to deceiving and being deceived, and I keep at +least a couple of pokes in the ribs ready for the blind rage with which +philosophers struggle against being deceived. Why NOT? It is nothing +more than a moral prejudice that truth is worth more than semblance; it +is, in fact, the worst proved supposition in the world. So much must be +conceded: there could have been no life at all except upon the basis +of perspective estimates and semblances; and if, with the virtuous +enthusiasm and stupidity of many philosophers, one wished to do away +altogether with the "seeming world"--well, granted that YOU could do +that,--at least nothing of your "truth" would thereby remain! Indeed, +what is it that forces us in general to the supposition that there is an +essential opposition of "true" and "false"? Is it not enough to suppose +degrees of seemingness, and as it were lighter and darker shades and +tones of semblance--different valeurs, as the painters say? Why might +not the world WHICH CONCERNS US--be a fiction? And to any one who +suggested: "But to a fiction belongs an originator?"--might it not be +bluntly replied: WHY? May not this "belong" also belong to the fiction? +Is it not at length permitted to be a little ironical towards the +subject, just as towards the predicate and object? Might not the +philosopher elevate himself above faith in grammar? All respect +to governesses, but is it not time that philosophy should renounce +governess-faith? + +35. O Voltaire! O humanity! O idiocy! There is something ticklish in +"the truth," and in the SEARCH for the truth; and if man goes about it +too humanely--"il ne cherche le vrai que pour faire le bien"--I wager he +finds nothing! + +36. Supposing that nothing else is "given" as real but our world of +desires and passions, that we cannot sink or rise to any other "reality" +but just that of our impulses--for thinking is only a relation of these +impulses to one another:--are we not permitted to make the attempt and +to ask the question whether this which is "given" does not SUFFICE, by +means of our counterparts, for the understanding even of the so-called +mechanical (or "material") world? I do not mean as an illusion, a +"semblance," a "representation" (in the Berkeleyan and Schopenhauerian +sense), but as possessing the same degree of reality as our emotions +themselves--as a more primitive form of the world of emotions, in +which everything still lies locked in a mighty unity, which afterwards +branches off and develops itself in organic processes (naturally also, +refines and debilitates)--as a kind of instinctive life in which all +organic functions, including self-regulation, assimilation, nutrition, +secretion, and change of matter, are still synthetically united with +one another--as a PRIMARY FORM of life?--In the end, it is not only +permitted to make this attempt, it is commanded by the conscience of +LOGICAL METHOD. Not to assume several kinds of causality, so long as +the attempt to get along with a single one has not been pushed to its +furthest extent (to absurdity, if I may be allowed to say so): that is +a morality of method which one may not repudiate nowadays--it follows +"from its definition," as mathematicians say. The question is ultimately +whether we really recognize the will as OPERATING, whether we believe in +the causality of the will; if we do so--and fundamentally our belief IN +THIS is just our belief in causality itself--we MUST make the attempt +to posit hypothetically the causality of the will as the only causality. +"Will" can naturally only operate on "will"--and not on "matter" (not +on "nerves," for instance): in short, the hypothesis must be +hazarded, whether will does not operate on will wherever "effects" +are recognized--and whether all mechanical action, inasmuch as a power +operates therein, is not just the power of will, the effect of will. +Granted, finally, that we succeeded in explaining our entire instinctive +life as the development and ramification of one fundamental form of +will--namely, the Will to Power, as my thesis puts it; granted that all +organic functions could be traced back to this Will to Power, and that +the solution of the problem of generation and nutrition--it is one +problem--could also be found therein: one would thus have acquired the +right to define ALL active force unequivocally as WILL TO POWER. The +world seen from within, the world defined and designated according to +its "intelligible character"--it would simply be "Will to Power," and +nothing else. + +37. "What? Does not that mean in popular language: God is disproved, but +not the devil?"--On the contrary! On the contrary, my friends! And who +the devil also compels you to speak popularly! + +38. As happened finally in all the enlightenment of modern times with +the French Revolution (that terrible farce, quite superfluous when +judged close at hand, into which, however, the noble and visionary +spectators of all Europe have interpreted from a distance their own +indignation and enthusiasm so long and passionately, UNTIL THE TEXT HAS +DISAPPEARED UNDER THE INTERPRETATION), so a noble posterity might once +more misunderstand the whole of the past, and perhaps only thereby make +ITS aspect endurable.--Or rather, has not this already happened? Have +not we ourselves been--that "noble posterity"? And, in so far as we now +comprehend this, is it not--thereby already past? + +39. Nobody will very readily regard a doctrine as true merely because +it makes people happy or virtuous--excepting, perhaps, the amiable +"Idealists," who are enthusiastic about the good, true, and beautiful, +and let all kinds of motley, coarse, and good-natured desirabilities +swim about promiscuously in their pond. Happiness and virtue are no +arguments. It is willingly forgotten, however, even on the part of +thoughtful minds, that to make unhappy and to make bad are just as +little counter-arguments. A thing could be TRUE, although it were in +the highest degree injurious and dangerous; indeed, the fundamental +constitution of existence might be such that one succumbed by a full +knowledge of it--so that the strength of a mind might be measured by +the amount of "truth" it could endure--or to speak more plainly, by the +extent to which it REQUIRED truth attenuated, veiled, sweetened, damped, +and falsified. But there is no doubt that for the discovery of certain +PORTIONS of truth the wicked and unfortunate are more favourably +situated and have a greater likelihood of success; not to speak of the +wicked who are happy--a species about whom moralists are silent. Perhaps +severity and craft are more favourable conditions for the development of +strong, independent spirits and philosophers than the gentle, refined, +yielding good-nature, and habit of taking things easily, which are +prized, and rightly prized in a learned man. Presupposing always, +to begin with, that the term "philosopher" be not confined to the +philosopher who writes books, or even introduces HIS philosophy into +books!--Stendhal furnishes a last feature of the portrait of the +free-spirited philosopher, which for the sake of German taste I will +not omit to underline--for it is OPPOSED to German taste. "Pour etre +bon philosophe," says this last great psychologist, "il faut etre sec, +clair, sans illusion. Un banquier, qui a fait fortune, a une partie du +caractere requis pour faire des decouvertes en philosophie, c'est-a-dire +pour voir clair dans ce qui est." + +40. Everything that is profound loves the mask: the profoundest things +have a hatred even of figure and likeness. Should not the CONTRARY only +be the right disguise for the shame of a God to go about in? A question +worth asking!--it would be strange if some mystic has not already +ventured on the same kind of thing. There are proceedings of such a +delicate nature that it is well to overwhelm them with coarseness +and make them unrecognizable; there are actions of love and of an +extravagant magnanimity after which nothing can be wiser than to take +a stick and thrash the witness soundly: one thereby obscures his +recollection. Many a one is able to obscure and abuse his own memory, in +order at least to have vengeance on this sole party in the secret: +shame is inventive. They are not the worst things of which one is +most ashamed: there is not only deceit behind a mask--there is so much +goodness in craft. I could imagine that a man with something costly and +fragile to conceal, would roll through life clumsily and rotundly like +an old, green, heavily-hooped wine-cask: the refinement of his shame +requiring it to be so. A man who has depths in his shame meets his +destiny and his delicate decisions upon paths which few ever reach, +and with regard to the existence of which his nearest and most intimate +friends may be ignorant; his mortal danger conceals itself from their +eyes, and equally so his regained security. Such a hidden nature, +which instinctively employs speech for silence and concealment, and is +inexhaustible in evasion of communication, DESIRES and insists that a +mask of himself shall occupy his place in the hearts and heads of his +friends; and supposing he does not desire it, his eyes will some day be +opened to the fact that there is nevertheless a mask of him there--and +that it is well to be so. Every profound spirit needs a mask; nay, more, +around every profound spirit there continually grows a mask, owing to +the constantly false, that is to say, SUPERFICIAL interpretation +of every word he utters, every step he takes, every sign of life he +manifests. + +41. One must subject oneself to one's own tests that one is destined +for independence and command, and do so at the right time. One must not +avoid one's tests, although they constitute perhaps the most dangerous +game one can play, and are in the end tests made only before ourselves +and before no other judge. Not to cleave to any person, be it even the +dearest--every person is a prison and also a recess. Not to cleave to +a fatherland, be it even the most suffering and necessitous--it is even +less difficult to detach one's heart from a victorious fatherland. Not +to cleave to a sympathy, be it even for higher men, into whose peculiar +torture and helplessness chance has given us an insight. Not to cleave +to a science, though it tempt one with the most valuable discoveries, +apparently specially reserved for us. Not to cleave to one's own +liberation, to the voluptuous distance and remoteness of the bird, which +always flies further aloft in order always to see more under it--the +danger of the flier. Not to cleave to our own virtues, nor become as +a whole a victim to any of our specialties, to our "hospitality" for +instance, which is the danger of dangers for highly developed +and wealthy souls, who deal prodigally, almost indifferently with +themselves, and push the virtue of liberality so far that it becomes +a vice. One must know how TO CONSERVE ONESELF--the best test of +independence. + +42. A new order of philosophers is appearing; I shall venture to baptize +them by a name not without danger. As far as I understand them, as far +as they allow themselves to be understood--for it is their nature to +WISH to remain something of a puzzle--these philosophers of the +future might rightly, perhaps also wrongly, claim to be designated as +"tempters." This name itself is after all only an attempt, or, if it be +preferred, a temptation. + +43. Will they be new friends of "truth," these coming philosophers? Very +probably, for all philosophers hitherto have loved their truths. But +assuredly they will not be dogmatists. It must be contrary to their +pride, and also contrary to their taste, that their truth should still +be truth for every one--that which has hitherto been the secret wish +and ultimate purpose of all dogmatic efforts. "My opinion is MY opinion: +another person has not easily a right to it"--such a philosopher of the +future will say, perhaps. One must renounce the bad taste of wishing to +agree with many people. "Good" is no longer good when one's neighbour +takes it into his mouth. And how could there be a "common good"! The +expression contradicts itself; that which can be common is always of +small value. In the end things must be as they are and have always +been--the great things remain for the great, the abysses for the +profound, the delicacies and thrills for the refined, and, to sum up +shortly, everything rare for the rare. + + +44. Need I say expressly after all this that they will be free, VERY +free spirits, these philosophers of the future--as certainly also they +will not be merely free spirits, but something more, higher, greater, +and fundamentally different, which does not wish to be misunderstood and +mistaken? But while I say this, I feel under OBLIGATION almost as much +to them as to ourselves (we free spirits who are their heralds and +forerunners), to sweep away from ourselves altogether a stupid old +prejudice and misunderstanding, which, like a fog, has too long made the +conception of "free spirit" obscure. In every country of Europe, and the +same in America, there is at present something which makes an abuse of +this name a very narrow, prepossessed, enchained class of spirits, +who desire almost the opposite of what our intentions and instincts +prompt--not to mention that in respect to the NEW philosophers who are +appearing, they must still more be closed windows and bolted doors. +Briefly and regrettably, they belong to the LEVELLERS, these wrongly +named "free spirits"--as glib-tongued and scribe-fingered slaves of +the democratic taste and its "modern ideas" all of them men without +solitude, without personal solitude, blunt honest fellows to whom +neither courage nor honourable conduct ought to be denied, only, they +are not free, and are ludicrously superficial, especially in their +innate partiality for seeing the cause of almost ALL human misery and +failure in the old forms in which society has hitherto existed--a notion +which happily inverts the truth entirely! What they would fain attain +with all their strength, is the universal, green-meadow happiness of the +herd, together with security, safety, comfort, and alleviation of life +for every one, their two most frequently chanted songs and doctrines +are called "Equality of Rights" and "Sympathy with All Sufferers"--and +suffering itself is looked upon by them as something which must be +DONE AWAY WITH. We opposite ones, however, who have opened our eye and +conscience to the question how and where the plant "man" has hitherto +grown most vigorously, believe that this has always taken place under +the opposite conditions, that for this end the dangerousness of his +situation had to be increased enormously, his inventive faculty and +dissembling power (his "spirit") had to develop into subtlety and daring +under long oppression and compulsion, and his Will to Life had to be +increased to the unconditioned Will to Power--we believe that severity, +violence, slavery, danger in the street and in the heart, secrecy, +stoicism, tempter's art and devilry of every kind,--that everything +wicked, terrible, tyrannical, predatory, and serpentine in man, serves +as well for the elevation of the human species as its opposite--we do +not even say enough when we only say THIS MUCH, and in any case we +find ourselves here, both with our speech and our silence, at the OTHER +extreme of all modern ideology and gregarious desirability, as their +antipodes perhaps? What wonder that we "free spirits" are not exactly +the most communicative spirits? that we do not wish to betray in every +respect WHAT a spirit can free itself from, and WHERE perhaps it will +then be driven? And as to the import of the dangerous formula, "Beyond +Good and Evil," with which we at least avoid confusion, we ARE something +else than "libres-penseurs," "liben pensatori" "free-thinkers," +and whatever these honest advocates of "modern ideas" like to call +themselves. Having been at home, or at least guests, in many realms of +the spirit, having escaped again and again from the gloomy, agreeable +nooks in which preferences and prejudices, youth, origin, the accident +of men and books, or even the weariness of travel seemed to confine us, +full of malice against the seductions of dependency which he concealed +in honours, money, positions, or exaltation of the senses, grateful even +for distress and the vicissitudes of illness, because they always free +us from some rule, and its "prejudice," grateful to the God, devil, +sheep, and worm in us, inquisitive to a fault, investigators to the +point of cruelty, with unhesitating fingers for the intangible, with +teeth and stomachs for the most indigestible, ready for any business +that requires sagacity and acute senses, ready for every adventure, +owing to an excess of "free will", with anterior and posterior souls, +into the ultimate intentions of which it is difficult to pry, with +foregrounds and backgrounds to the end of which no foot may run, hidden +ones under the mantles of light, appropriators, although we resemble +heirs and spendthrifts, arrangers and collectors from morning till +night, misers of our wealth and our full-crammed drawers, economical +in learning and forgetting, inventive in scheming, sometimes proud of +tables of categories, sometimes pedants, sometimes night-owls of +work even in full day, yea, if necessary, even scarecrows--and it is +necessary nowadays, that is to say, inasmuch as we are the born, sworn, +jealous friends of SOLITUDE, of our own profoundest midnight and midday +solitude--such kind of men are we, we free spirits! And perhaps ye are +also something of the same kind, ye coming ones? ye NEW philosophers? + + + +CHAPTER III. THE RELIGIOUS MOOD + + +45. The human soul and its limits, the range of man's inner experiences +hitherto attained, the heights, depths, and distances of these +experiences, the entire history of the soul UP TO THE PRESENT TIME, +and its still unexhausted possibilities: this is the preordained +hunting-domain for a born psychologist and lover of a "big hunt". But +how often must he say despairingly to himself: "A single individual! +alas, only a single individual! and this great forest, this virgin +forest!" So he would like to have some hundreds of hunting assistants, +and fine trained hounds, that he could send into the history of the +human soul, to drive HIS game together. In vain: again and again he +experiences, profoundly and bitterly, how difficult it is to find +assistants and dogs for all the things that directly excite his +curiosity. The evil of sending scholars into new and dangerous +hunting-domains, where courage, sagacity, and subtlety in every sense +are required, is that they are no longer serviceable just when the "BIG +hunt," and also the great danger commences,--it is precisely then that +they lose their keen eye and nose. In order, for instance, to divine and +determine what sort of history the problem of KNOWLEDGE AND CONSCIENCE +has hitherto had in the souls of homines religiosi, a person would +perhaps himself have to possess as profound, as bruised, as immense an +experience as the intellectual conscience of Pascal; and then he would +still require that wide-spread heaven of clear, wicked spirituality, +which, from above, would be able to oversee, arrange, and effectively +formulize this mass of dangerous and painful experiences.--But who +could do me this service! And who would have time to wait for such +servants!--they evidently appear too rarely, they are so improbable at +all times! Eventually one must do everything ONESELF in order to know +something; which means that one has MUCH to do!--But a curiosity like +mine is once for all the most agreeable of vices--pardon me! I mean to +say that the love of truth has its reward in heaven, and already upon +earth. + +46. Faith, such as early Christianity desired, and not infrequently +achieved in the midst of a skeptical and southernly free-spirited world, +which had centuries of struggle between philosophical schools behind +it and in it, counting besides the education in tolerance which +the Imperium Romanum gave--this faith is NOT that sincere, austere +slave-faith by which perhaps a Luther or a Cromwell, or some other +northern barbarian of the spirit remained attached to his God and +Christianity, it is much rather the faith of Pascal, which resembles in +a terrible manner a continuous suicide of reason--a tough, long-lived, +worm-like reason, which is not to be slain at once and with a single +blow. The Christian faith from the beginning, is sacrifice the sacrifice +of all freedom, all pride, all self-confidence of spirit, it is at +the same time subjection, self-derision, and self-mutilation. There is +cruelty and religious Phoenicianism in this faith, which is adapted to a +tender, many-sided, and very fastidious conscience, it takes for granted +that the subjection of the spirit is indescribably PAINFUL, that all the +past and all the habits of such a spirit resist the absurdissimum, in +the form of which "faith" comes to it. Modern men, with their obtuseness +as regards all Christian nomenclature, have no longer the sense for the +terribly superlative conception which was implied to an antique taste by +the paradox of the formula, "God on the Cross". Hitherto there had never +and nowhere been such boldness in inversion, nor anything at once so +dreadful, questioning, and questionable as this formula: it promised a +transvaluation of all ancient values--It was the Orient, the PROFOUND +Orient, it was the Oriental slave who thus took revenge on Rome and its +noble, light-minded toleration, on the Roman "Catholicism" of non-faith, +and it was always not the faith, but the freedom from the faith, the +half-stoical and smiling indifference to the seriousness of the faith, +which made the slaves indignant at their masters and revolt against +them. "Enlightenment" causes revolt, for the slave desires the +unconditioned, he understands nothing but the tyrannous, even in morals, +he loves as he hates, without NUANCE, to the very depths, to the point +of pain, to the point of sickness--his many HIDDEN sufferings make +him revolt against the noble taste which seems to DENY suffering. The +skepticism with regard to suffering, fundamentally only an attitude of +aristocratic morality, was not the least of the causes, also, of the +last great slave-insurrection which began with the French Revolution. + +47. Wherever the religious neurosis has appeared on the earth so far, +we find it connected with three dangerous prescriptions as to regimen: +solitude, fasting, and sexual abstinence--but without its being possible +to determine with certainty which is cause and which is effect, or IF +any relation at all of cause and effect exists there. This latter doubt +is justified by the fact that one of the most regular symptoms among +savage as well as among civilized peoples is the most sudden and +excessive sensuality, which then with equal suddenness transforms into +penitential paroxysms, world-renunciation, and will-renunciation, both +symptoms perhaps explainable as disguised epilepsy? But nowhere is it +MORE obligatory to put aside explanations around no other type has there +grown such a mass of absurdity and superstition, no other type seems to +have been more interesting to men and even to philosophers--perhaps it +is time to become just a little indifferent here, to learn caution, or, +better still, to look AWAY, TO GO AWAY--Yet in the background of the +most recent philosophy, that of Schopenhauer, we find almost as the +problem in itself, this terrible note of interrogation of the religious +crisis and awakening. How is the negation of will POSSIBLE? how is the +saint possible?--that seems to have been the very question with which +Schopenhauer made a start and became a philosopher. And thus it was a +genuine Schopenhauerian consequence, that his most convinced adherent +(perhaps also his last, as far as Germany is concerned), namely, Richard +Wagner, should bring his own life-work to an end just here, and should +finally put that terrible and eternal type upon the stage as Kundry, +type vecu, and as it loved and lived, at the very time that the +mad-doctors in almost all European countries had an opportunity to study +the type close at hand, wherever the religious neurosis--or as I call +it, "the religious mood"--made its latest epidemical outbreak and +display as the "Salvation Army"--If it be a question, however, as to +what has been so extremely interesting to men of all sorts in all ages, +and even to philosophers, in the whole phenomenon of the saint, it +is undoubtedly the appearance of the miraculous therein--namely, the +immediate SUCCESSION OF OPPOSITES, of states of the soul regarded as +morally antithetical: it was believed here to be self-evident that +a "bad man" was all at once turned into a "saint," a good man. The +hitherto existing psychology was wrecked at this point, is it not +possible it may have happened principally because psychology had placed +itself under the dominion of morals, because it BELIEVED in oppositions +of moral values, and saw, read, and INTERPRETED these oppositions +into the text and facts of the case? What? "Miracle" only an error of +interpretation? A lack of philology? + +48. It seems that the Latin races are far more deeply attached to their +Catholicism than we Northerners are to Christianity generally, and +that consequently unbelief in Catholic countries means something quite +different from what it does among Protestants--namely, a sort of revolt +against the spirit of the race, while with us it is rather a return to +the spirit (or non-spirit) of the race. + +We Northerners undoubtedly derive our origin from barbarous races, even +as regards our talents for religion--we have POOR talents for it. One +may make an exception in the case of the Celts, who have theretofore +furnished also the best soil for Christian infection in the North: the +Christian ideal blossomed forth in France as much as ever the pale sun +of the north would allow it. How strangely pious for our taste are still +these later French skeptics, whenever there is any Celtic blood in their +origin! How Catholic, how un-German does Auguste Comte's Sociology +seem to us, with the Roman logic of its instincts! How Jesuitical, that +amiable and shrewd cicerone of Port Royal, Sainte-Beuve, in spite of all +his hostility to Jesuits! And even Ernest Renan: how inaccessible to +us Northerners does the language of such a Renan appear, in whom +every instant the merest touch of religious thrill throws his refined +voluptuous and comfortably couching soul off its balance! Let us repeat +after him these fine sentences--and what wickedness and haughtiness is +immediately aroused by way of answer in our probably less beautiful but +harder souls, that is to say, in our more German souls!--"DISONS DONC +HARDIMENT QUE LA RELIGION EST UN PRODUIT DE L'HOMME NORMAL, QUE L'HOMME +EST LE PLUS DANS LE VRAI QUANT IL EST LE PLUS RELIGIEUX ET LE PLUS +ASSURE D'UNE DESTINEE INFINIE.... C'EST QUAND IL EST BON QU'IL VEUT QUE +LA VIRTU CORRESPONDE A UN ORDER ETERNAL, C'EST QUAND IL CONTEMPLE LES +CHOSES D'UNE MANIERE DESINTERESSEE QU'IL TROUVE LA MORT REVOLTANTE ET +ABSURDE. COMMENT NE PAS SUPPOSER QUE C'EST DANS CES MOMENTS-LA, QUE +L'HOMME VOIT LE MIEUX?"... These sentences are so extremely ANTIPODAL +to my ears and habits of thought, that in my first impulse of rage +on finding them, I wrote on the margin, "LA NIAISERIE RELIGIEUSE PAR +EXCELLENCE!"--until in my later rage I even took a fancy to them, these +sentences with their truth absolutely inverted! It is so nice and such a +distinction to have one's own antipodes! + +49. That which is so astonishing in the religious life of the ancient +Greeks is the irrestrainable stream of GRATITUDE which it pours +forth--it is a very superior kind of man who takes SUCH an attitude +towards nature and life.--Later on, when the populace got the upper hand +in Greece, FEAR became rampant also in religion; and Christianity was +preparing itself. + +50. The passion for God: there are churlish, honest-hearted, and +importunate kinds of it, like that of Luther--the whole of Protestantism +lacks the southern DELICATEZZA. There is an Oriental exaltation of the +mind in it, like that of an undeservedly favoured or elevated slave, as +in the case of St. Augustine, for instance, who lacks in an offensive +manner, all nobility in bearing and desires. There is a feminine +tenderness and sensuality in it, which modestly and unconsciously longs +for a UNIO MYSTICA ET PHYSICA, as in the case of Madame de Guyon. In +many cases it appears, curiously enough, as the disguise of a girl's +or youth's puberty; here and there even as the hysteria of an old maid, +also as her last ambition. The Church has frequently canonized the woman +in such a case. + +51. The mightiest men have hitherto always bowed reverently before +the saint, as the enigma of self-subjugation and utter voluntary +privation--why did they thus bow? They divined in him--and as it were +behind the questionableness of his frail and wretched appearance--the +superior force which wished to test itself by such a subjugation; the +strength of will, in which they recognized their own strength and +love of power, and knew how to honour it: they honoured something +in themselves when they honoured the saint. In addition to this, the +contemplation of the saint suggested to them a suspicion: such an +enormity of self-negation and anti-naturalness will not have been +coveted for nothing--they have said, inquiringly. There is perhaps a +reason for it, some very great danger, about which the ascetic might +wish to be more accurately informed through his secret interlocutors and +visitors? In a word, the mighty ones of the world learned to have a new +fear before him, they divined a new power, a strange, still unconquered +enemy:--it was the "Will to Power" which obliged them to halt before the +saint. They had to question him. + +52. In the Jewish "Old Testament," the book of divine justice, there are +men, things, and sayings on such an immense scale, that Greek and Indian +literature has nothing to compare with it. One stands with fear and +reverence before those stupendous remains of what man was formerly, and +one has sad thoughts about old Asia and its little out-pushed peninsula +Europe, which would like, by all means, to figure before Asia as the +"Progress of Mankind." To be sure, he who is himself only a slender, +tame house-animal, and knows only the wants of a house-animal (like +our cultured people of today, including the Christians of "cultured" +Christianity), need neither be amazed nor even sad amid those ruins--the +taste for the Old Testament is a touchstone with respect to "great" and +"small": perhaps he will find that the New Testament, the book of grace, +still appeals more to his heart (there is much of the odour of the +genuine, tender, stupid beadsman and petty soul in it). To have bound +up this New Testament (a kind of ROCOCO of taste in every respect) along +with the Old Testament into one book, as the "Bible," as "The Book in +Itself," is perhaps the greatest audacity and "sin against the Spirit" +which literary Europe has upon its conscience. + +53. Why Atheism nowadays? "The father" in God is thoroughly refuted; +equally so "the judge," "the rewarder." Also his "free will": he does +not hear--and even if he did, he would not know how to help. The worst +is that he seems incapable of communicating himself clearly; is he +uncertain?--This is what I have made out (by questioning and listening +at a variety of conversations) to be the cause of the decline of +European theism; it appears to me that though the religious instinct is +in vigorous growth,--it rejects the theistic satisfaction with profound +distrust. + +54. What does all modern philosophy mainly do? Since Descartes--and +indeed more in defiance of him than on the basis of his procedure--an +ATTENTAT has been made on the part of all philosophers on the old +conception of the soul, under the guise of a criticism of the subject +and predicate conception--that is to say, an ATTENTAT on the +fundamental presupposition of Christian doctrine. Modern philosophy, +as epistemological skepticism, is secretly or openly ANTI-CHRISTIAN, +although (for keener ears, be it said) by no means anti-religious. +Formerly, in effect, one believed in "the soul" as one believed in +grammar and the grammatical subject: one said, "I" is the condition, +"think" is the predicate and is conditioned--to think is an activity for +which one MUST suppose a subject as cause. The attempt was then made, +with marvelous tenacity and subtlety, to see if one could not get out +of this net,--to see if the opposite was not perhaps true: "think" the +condition, and "I" the conditioned; "I," therefore, only a synthesis +which has been MADE by thinking itself. KANT really wished to prove +that, starting from the subject, the subject could not be proved--nor +the object either: the possibility of an APPARENT EXISTENCE of the +subject, and therefore of "the soul," may not always have been strange +to him,--the thought which once had an immense power on earth as the +Vedanta philosophy. + +55. There is a great ladder of religious cruelty, with many rounds; but +three of these are the most important. Once on a time men sacrificed +human beings to their God, and perhaps just those they loved the +best--to this category belong the firstling sacrifices of all primitive +religions, and also the sacrifice of the Emperor Tiberius in the +Mithra-Grotto on the Island of Capri, that most terrible of all Roman +anachronisms. Then, during the moral epoch of mankind, they sacrificed +to their God the strongest instincts they possessed, their "nature"; +THIS festal joy shines in the cruel glances of ascetics and +"anti-natural" fanatics. Finally, what still remained to be sacrificed? +Was it not necessary in the end for men to sacrifice everything +comforting, holy, healing, all hope, all faith in hidden harmonies, in +future blessedness and justice? Was it not necessary to sacrifice God +himself, and out of cruelty to themselves to worship stone, stupidity, +gravity, fate, nothingness? To sacrifice God for nothingness--this +paradoxical mystery of the ultimate cruelty has been reserved for the +rising generation; we all know something thereof already. + +56. Whoever, like myself, prompted by some enigmatical desire, has long +endeavoured to go to the bottom of the question of pessimism and free it +from the half-Christian, half-German narrowness and stupidity in which +it has finally presented itself to this century, namely, in the form of +Schopenhauer's philosophy; whoever, with an Asiatic and super-Asiatic +eye, has actually looked inside, and into the most world-renouncing of +all possible modes of thought--beyond good and evil, and no longer +like Buddha and Schopenhauer, under the dominion and delusion of +morality,--whoever has done this, has perhaps just thereby, without +really desiring it, opened his eyes to behold the opposite ideal: the +ideal of the most world-approving, exuberant, and vivacious man, who has +not only learnt to compromise and arrange with that which was and +is, but wishes to have it again AS IT WAS AND IS, for all eternity, +insatiably calling out da capo, not only to himself, but to the whole +piece and play; and not only the play, but actually to him who requires +the play--and makes it necessary; because he always requires +himself anew--and makes himself necessary.--What? And this would not +be--circulus vitiosus deus? + +57. The distance, and as it were the space around man, grows with the +strength of his intellectual vision and insight: his world becomes +profounder; new stars, new enigmas, and notions are ever coming into +view. Perhaps everything on which the intellectual eye has exercised +its acuteness and profundity has just been an occasion for its exercise, +something of a game, something for children and childish minds. Perhaps +the most solemn conceptions that have caused the most fighting and +suffering, the conceptions "God" and "sin," will one day seem to us of +no more importance than a child's plaything or a child's pain seems to +an old man;--and perhaps another plaything and another pain will then +be necessary once more for "the old man"--always childish enough, an +eternal child! + +58. Has it been observed to what extent outward idleness, or +semi-idleness, is necessary to a real religious life (alike for its +favourite microscopic labour of self-examination, and for its soft +placidity called "prayer," the state of perpetual readiness for the +"coming of God"), I mean the idleness with a good conscience, the +idleness of olden times and of blood, to which the aristocratic +sentiment that work is DISHONOURING--that it vulgarizes body and +soul--is not quite unfamiliar? And that consequently the modern, noisy, +time-engrossing, conceited, foolishly proud laboriousness educates +and prepares for "unbelief" more than anything else? Among these, for +instance, who are at present living apart from religion in Germany, I +find "free-thinkers" of diversified species and origin, but above all +a majority of those in whom laboriousness from generation to generation +has dissolved the religious instincts; so that they no longer know what +purpose religions serve, and only note their existence in the world +with a kind of dull astonishment. They feel themselves already fully +occupied, these good people, be it by their business or by their +pleasures, not to mention the "Fatherland," and the newspapers, and +their "family duties"; it seems that they have no time whatever left +for religion; and above all, it is not obvious to them whether it is a +question of a new business or a new pleasure--for it is impossible, they +say to themselves, that people should go to church merely to spoil +their tempers. They are by no means enemies of religious customs; +should certain circumstances, State affairs perhaps, require their +participation in such customs, they do what is required, as so many +things are done--with a patient and unassuming seriousness, and without +much curiosity or discomfort;--they live too much apart and outside +to feel even the necessity for a FOR or AGAINST in such matters. Among +those indifferent persons may be reckoned nowadays the majority of +German Protestants of the middle classes, especially in the great +laborious centres of trade and commerce; also the majority of laborious +scholars, and the entire University personnel (with the exception of +the theologians, whose existence and possibility there always gives +psychologists new and more subtle puzzles to solve). On the part of +pious, or merely church-going people, there is seldom any idea of HOW +MUCH good-will, one might say arbitrary will, is now necessary for a +German scholar to take the problem of religion seriously; his whole +profession (and as I have said, his whole workmanlike laboriousness, to +which he is compelled by his modern conscience) inclines him to a +lofty and almost charitable serenity as regards religion, with which is +occasionally mingled a slight disdain for the "uncleanliness" of spirit +which he takes for granted wherever any one still professes to belong +to the Church. It is only with the help of history (NOT through his own +personal experience, therefore) that the scholar succeeds in bringing +himself to a respectful seriousness, and to a certain timid deference +in presence of religions; but even when his sentiments have reached the +stage of gratitude towards them, he has not personally advanced one +step nearer to that which still maintains itself as Church or as piety; +perhaps even the contrary. The practical indifference to religious +matters in the midst of which he has been born and brought up, usually +sublimates itself in his case into circumspection and cleanliness, which +shuns contact with religious men and things; and it may be just the +depth of his tolerance and humanity which prompts him to avoid the +delicate trouble which tolerance itself brings with it.--Every age has +its own divine type of naivete, for the discovery of which other ages +may envy it: and how much naivete--adorable, childlike, and boundlessly +foolish naivete is involved in this belief of the scholar in +his superiority, in the good conscience of his tolerance, in the +unsuspecting, simple certainty with which his instinct treats the +religious man as a lower and less valuable type, beyond, before, and +ABOVE which he himself has developed--he, the little arrogant dwarf +and mob-man, the sedulously alert, head-and-hand drudge of "ideas," of +"modern ideas"! + +59. Whoever has seen deeply into the world has doubtless divined what +wisdom there is in the fact that men are superficial. It is their +preservative instinct which teaches them to be flighty, lightsome, and +false. Here and there one finds a passionate and exaggerated adoration +of "pure forms" in philosophers as well as in artists: it is not to be +doubted that whoever has NEED of the cult of the superficial to that +extent, has at one time or another made an unlucky dive BENEATH it. +Perhaps there is even an order of rank with respect to those burnt +children, the born artists who find the enjoyment of life only in trying +to FALSIFY its image (as if taking wearisome revenge on it), one might +guess to what degree life has disgusted them, by the extent to which +they wish to see its image falsified, attenuated, ultrified, and +deified,--one might reckon the homines religiosi among the artists, as +their HIGHEST rank. It is the profound, suspicious fear of an incurable +pessimism which compels whole centuries to fasten their teeth into a +religious interpretation of existence: the fear of the instinct which +divines that truth might be attained TOO soon, before man has become +strong enough, hard enough, artist enough.... Piety, the "Life in God," +regarded in this light, would appear as the most elaborate and +ultimate product of the FEAR of truth, as artist-adoration +and artist-intoxication in presence of the most logical of all +falsifications, as the will to the inversion of truth, to untruth at +any price. Perhaps there has hitherto been no more effective means of +beautifying man than piety, by means of it man can become so artful, so +superficial, so iridescent, and so good, that his appearance no longer +offends. + +60. To love mankind FOR GOD'S SAKE--this has so far been the noblest and +remotest sentiment to which mankind has attained. That love to mankind, +without any redeeming intention in the background, is only an ADDITIONAL +folly and brutishness, that the inclination to this love has first to +get its proportion, its delicacy, its gram of salt and sprinkling +of ambergris from a higher inclination--whoever first perceived +and "experienced" this, however his tongue may have stammered as it +attempted to express such a delicate matter, let him for all time be +holy and respected, as the man who has so far flown highest and gone +astray in the finest fashion! + +61. The philosopher, as WE free spirits understand him--as the man of +the greatest responsibility, who has the conscience for the general +development of mankind,--will use religion for his disciplining and +educating work, just as he will use the contemporary political +and economic conditions. The selecting and disciplining +influence--destructive, as well as creative and fashioning--which can be +exercised by means of religion is manifold and varied, according to the +sort of people placed under its spell and protection. For those who are +strong and independent, destined and trained to command, in whom the +judgment and skill of a ruling race is incorporated, religion is +an additional means for overcoming resistance in the exercise of +authority--as a bond which binds rulers and subjects in common, +betraying and surrendering to the former the conscience of the latter, +their inmost heart, which would fain escape obedience. And in the +case of the unique natures of noble origin, if by virtue of superior +spirituality they should incline to a more retired and contemplative +life, reserving to themselves only the more refined forms of government +(over chosen disciples or members of an order), religion itself may +be used as a means for obtaining peace from the noise and trouble of +managing GROSSER affairs, and for securing immunity from the UNAVOIDABLE +filth of all political agitation. The Brahmins, for instance, understood +this fact. With the help of a religious organization, they secured to +themselves the power of nominating kings for the people, while their +sentiments prompted them to keep apart and outside, as men with a higher +and super-regal mission. At the same time religion gives inducement and +opportunity to some of the subjects to qualify themselves for future +ruling and commanding the slowly ascending ranks and classes, in which, +through fortunate marriage customs, volitional power and delight in +self-control are on the increase. To them religion offers sufficient +incentives and temptations to aspire to higher intellectuality, and to +experience the sentiments of authoritative self-control, of silence, and +of solitude. Asceticism and Puritanism are almost indispensable means of +educating and ennobling a race which seeks to rise above its hereditary +baseness and work itself upwards to future supremacy. And finally, to +ordinary men, to the majority of the people, who exist for service and +general utility, and are only so far entitled to exist, religion gives +invaluable contentedness with their lot and condition, peace of heart, +ennoblement of obedience, additional social happiness and sympathy, +with something of transfiguration and embellishment, something of +justification of all the commonplaceness, all the meanness, all +the semi-animal poverty of their souls. Religion, together with the +religious significance of life, sheds sunshine over such perpetually +harassed men, and makes even their own aspect endurable to them, it +operates upon them as the Epicurean philosophy usually operates upon +sufferers of a higher order, in a refreshing and refining manner, +almost TURNING suffering TO ACCOUNT, and in the end even hallowing and +vindicating it. There is perhaps nothing so admirable in Christianity +and Buddhism as their art of teaching even the lowest to elevate +themselves by piety to a seemingly higher order of things, and thereby +to retain their satisfaction with the actual world in which they find it +difficult enough to live--this very difficulty being necessary. + +62. To be sure--to make also the bad counter-reckoning against such +religions, and to bring to light their secret dangers--the cost is +always excessive and terrible when religions do NOT operate as an +educational and disciplinary medium in the hands of the philosopher, but +rule voluntarily and PARAMOUNTLY, when they wish to be the final end, +and not a means along with other means. Among men, as among all other +animals, there is a surplus of defective, diseased, degenerating, +infirm, and necessarily suffering individuals; the successful cases, +among men also, are always the exception; and in view of the fact that +man is THE ANIMAL NOT YET PROPERLY ADAPTED TO HIS ENVIRONMENT, the rare +exception. But worse still. The higher the type a man represents, the +greater is the improbability that he will SUCCEED; the accidental, the +law of irrationality in the general constitution of mankind, manifests +itself most terribly in its destructive effect on the higher orders of +men, the conditions of whose lives are delicate, diverse, and difficult +to determine. What, then, is the attitude of the two greatest religions +above-mentioned to the SURPLUS of failures in life? They endeavour +to preserve and keep alive whatever can be preserved; in fact, as the +religions FOR SUFFERERS, they take the part of these upon principle; +they are always in favour of those who suffer from life as from a +disease, and they would fain treat every other experience of life as +false and impossible. However highly we may esteem this indulgent and +preservative care (inasmuch as in applying to others, it has applied, +and applies also to the highest and usually the most suffering type of +man), the hitherto PARAMOUNT religions--to give a general appreciation +of them--are among the principal causes which have kept the type of +"man" upon a lower level--they have preserved too much THAT WHICH SHOULD +HAVE PERISHED. One has to thank them for invaluable services; and who is +sufficiently rich in gratitude not to feel poor at the contemplation +of all that the "spiritual men" of Christianity have done for Europe +hitherto! But when they had given comfort to the sufferers, courage to +the oppressed and despairing, a staff and support to the helpless, +and when they had allured from society into convents and spiritual +penitentiaries the broken-hearted and distracted: what else had they +to do in order to work systematically in that fashion, and with a good +conscience, for the preservation of all the sick and suffering, which +means, in deed and in truth, to work for the DETERIORATION OF THE +EUROPEAN RACE? To REVERSE all estimates of value--THAT is what they +had to do! And to shatter the strong, to spoil great hopes, to cast +suspicion on the delight in beauty, to break down everything autonomous, +manly, conquering, and imperious--all instincts which are natural to the +highest and most successful type of "man"--into uncertainty, distress +of conscience, and self-destruction; forsooth, to invert all love of the +earthly and of supremacy over the earth, into hatred of the earth and +earthly things--THAT is the task the Church imposed on itself, and +was obliged to impose, until, according to its standard of value, +"unworldliness," "unsensuousness," and "higher man" fused into one +sentiment. If one could observe the strangely painful, equally coarse +and refined comedy of European Christianity with the derisive and +impartial eye of an Epicurean god, I should think one would never cease +marvelling and laughing; does it not actually seem that some single will +has ruled over Europe for eighteen centuries in order to make a SUBLIME +ABORTION of man? He, however, who, with opposite requirements (no longer +Epicurean) and with some divine hammer in his hand, could approach this +almost voluntary degeneration and stunting of mankind, as exemplified in +the European Christian (Pascal, for instance), would he not have to +cry aloud with rage, pity, and horror: "Oh, you bunglers, presumptuous +pitiful bunglers, what have you done! Was that a work for your hands? +How you have hacked and botched my finest stone! What have you presumed +to do!"--I should say that Christianity has hitherto been the most +portentous of presumptions. Men, not great enough, nor hard enough, +to be entitled as artists to take part in fashioning MAN; men, +not sufficiently strong and far-sighted to ALLOW, with sublime +self-constraint, the obvious law of the thousandfold failures and +perishings to prevail; men, not sufficiently noble to see the radically +different grades of rank and intervals of rank that separate man from +man:--SUCH men, with their "equality before God," have hitherto swayed +the destiny of Europe; until at last a dwarfed, almost ludicrous species +has been produced, a gregarious animal, something obliging, sickly, +mediocre, the European of the present day. + + + +CHAPTER IV. APOPHTHEGMS AND INTERLUDES + + +63. He who is a thorough teacher takes things seriously--and even +himself--only in relation to his pupils. + +64. "Knowledge for its own sake"--that is the last snare laid by +morality: we are thereby completely entangled in morals once more. + +65. The charm of knowledge would be small, were it not so much shame has +to be overcome on the way to it. + +65A. We are most dishonourable towards our God: he is not PERMITTED to +sin. + +66. The tendency of a person to allow himself to be degraded, robbed, +deceived, and exploited might be the diffidence of a God among men. + +67. Love to one only is a barbarity, for it is exercised at the expense +of all others. Love to God also! + +68. "I did that," says my memory. "I could not have done that," says my +pride, and remains inexorable. Eventually--the memory yields. + +69. One has regarded life carelessly, if one has failed to see the hand +that--kills with leniency. + +70. If a man has character, he has also his typical experience, which +always recurs. + +71. THE SAGE AS ASTRONOMER.--So long as thou feelest the stars as an +"above thee," thou lackest the eye of the discerning one. + +72. It is not the strength, but the duration of great sentiments that +makes great men. + +73. He who attains his ideal, precisely thereby surpasses it. + +73A. Many a peacock hides his tail from every eye--and calls it his +pride. + +74. A man of genius is unbearable, unless he possess at least two things +besides: gratitude and purity. + +75. The degree and nature of a man's sensuality extends to the highest +altitudes of his spirit. + +76. Under peaceful conditions the militant man attacks himself. + +77. With his principles a man seeks either to dominate, or justify, +or honour, or reproach, or conceal his habits: two men with the same +principles probably seek fundamentally different ends therewith. + +78. He who despises himself, nevertheless esteems himself thereby, as a +despiser. + +79. A soul which knows that it is loved, but does not itself love, +betrays its sediment: its dregs come up. + +80. A thing that is explained ceases to concern us--What did the God +mean who gave the advice, "Know thyself!" Did it perhaps imply "Cease to +be concerned about thyself! become objective!"--And Socrates?--And the +"scientific man"? + +81. It is terrible to die of thirst at sea. Is it necessary that you +should so salt your truth that it will no longer--quench thirst? + +82. "Sympathy for all"--would be harshness and tyranny for THEE, my good +neighbour. + +83. INSTINCT--When the house is on fire one forgets even the +dinner--Yes, but one recovers it from among the ashes. + +84. Woman learns how to hate in proportion as she--forgets how to charm. + +85. The same emotions are in man and woman, but in different TEMPO, on +that account man and woman never cease to misunderstand each other. + +86. In the background of all their personal vanity, women themselves +have still their impersonal scorn--for "woman". + +87. FETTERED HEART, FREE SPIRIT--When one firmly fetters one's heart +and keeps it prisoner, one can allow one's spirit many liberties: I said +this once before But people do not believe it when I say so, unless they +know it already. + +88. One begins to distrust very clever persons when they become +embarrassed. + +89. Dreadful experiences raise the question whether he who experiences +them is not something dreadful also. + +90. Heavy, melancholy men turn lighter, and come temporarily to their +surface, precisely by that which makes others heavy--by hatred and love. + +91. So cold, so icy, that one burns one's finger at the touch of him! +Every hand that lays hold of him shrinks back!--And for that very reason +many think him red-hot. + +92. Who has not, at one time or another--sacrificed himself for the sake +of his good name? + +93. In affability there is no hatred of men, but precisely on that +account a great deal too much contempt of men. + +94. The maturity of man--that means, to have reacquired the seriousness +that one had as a child at play. + +95. To be ashamed of one's immorality is a step on the ladder at the end +of which one is ashamed also of one's morality. + +96. One should part from life as Ulysses parted from Nausicaa--blessing +it rather than in love with it. + +97. What? A great man? I always see merely the play-actor of his own +ideal. + +98. When one trains one's conscience, it kisses one while it bites. + +99. THE DISAPPOINTED ONE SPEAKS--"I listened for the echo and I heard +only praise." + +100. We all feign to ourselves that we are simpler than we are, we thus +relax ourselves away from our fellows. + +101. A discerning one might easily regard himself at present as the +animalization of God. + +102. Discovering reciprocal love should really disenchant the lover with +regard to the beloved. "What! She is modest enough to love even you? Or +stupid enough? Or--or---" + +103. THE DANGER IN HAPPINESS.--"Everything now turns out best for me, I +now love every fate:--who would like to be my fate?" + +104. Not their love of humanity, but the impotence of their love, +prevents the Christians of today--burning us. + +105. The pia fraus is still more repugnant to the taste (the "piety") +of the free spirit (the "pious man of knowledge") than the impia fraus. +Hence the profound lack of judgment, in comparison with the Church, +characteristic of the type "free spirit"--as ITS non-freedom. + +106. By means of music the very passions enjoy themselves. + +107. A sign of strong character, when once the resolution has been +taken, to shut the ear even to the best counter-arguments. Occasionally, +therefore, a will to stupidity. + +108. There is no such thing as moral phenomena, but only a moral +interpretation of phenomena. + +109. The criminal is often enough not equal to his deed: he extenuates +and maligns it. + +110. The advocates of a criminal are seldom artists enough to turn the +beautiful terribleness of the deed to the advantage of the doer. + +111. Our vanity is most difficult to wound just when our pride has been +wounded. + +112. To him who feels himself preordained to contemplation and not to +belief, all believers are too noisy and obtrusive; he guards against +them. + +113. "You want to prepossess him in your favour? Then you must be +embarrassed before him." + +114. The immense expectation with regard to sexual love, and the coyness +in this expectation, spoils all the perspectives of women at the outset. + +115. Where there is neither love nor hatred in the game, woman's play is +mediocre. + +116. The great epochs of our life are at the points when we gain courage +to rebaptize our badness as the best in us. + +117. The will to overcome an emotion, is ultimately only the will of +another, or of several other, emotions. + +118. There is an innocence of admiration: it is possessed by him to whom +it has not yet occurred that he himself may be admired some day. + +119. Our loathing of dirt may be so great as to prevent our cleaning +ourselves--"justifying" ourselves. + +120. Sensuality often forces the growth of love too much, so that its +root remains weak, and is easily torn up. + +121. It is a curious thing that God learned Greek when he wished to turn +author--and that he did not learn it better. + +122. To rejoice on account of praise is in many cases merely politeness +of heart--and the very opposite of vanity of spirit. + +123. Even concubinage has been corrupted--by marriage. + +124. He who exults at the stake, does not triumph over pain, but because +of the fact that he does not feel pain where he expected it. A parable. + +125. When we have to change an opinion about any one, we charge heavily +to his account the inconvenience he thereby causes us. + +126. A nation is a detour of nature to arrive at six or seven great +men.--Yes, and then to get round them. + +127. In the eyes of all true women science is hostile to the sense of +shame. They feel as if one wished to peep under their skin with it--or +worse still! under their dress and finery. + +128. The more abstract the truth you wish to teach, the more must you +allure the senses to it. + +129. The devil has the most extensive perspectives for God; on that +account he keeps so far away from him:--the devil, in effect, as the +oldest friend of knowledge. + +130. What a person IS begins to betray itself when his talent +decreases,--when he ceases to show what he CAN do. Talent is also an +adornment; an adornment is also a concealment. + +131. The sexes deceive themselves about each other: the reason is that +in reality they honour and love only themselves (or their own ideal, to +express it more agreeably). Thus man wishes woman to be peaceable: but +in fact woman is ESSENTIALLY unpeaceable, like the cat, however well she +may have assumed the peaceable demeanour. + +132. One is punished best for one's virtues. + +133. He who cannot find the way to HIS ideal, lives more frivolously and +shamelessly than the man without an ideal. + +134. From the senses originate all trustworthiness, all good conscience, +all evidence of truth. + +135. Pharisaism is not a deterioration of the good man; a considerable +part of it is rather an essential condition of being good. + +136. The one seeks an accoucheur for his thoughts, the other seeks some +one whom he can assist: a good conversation thus originates. + +137. In intercourse with scholars and artists one readily makes mistakes +of opposite kinds: in a remarkable scholar one not infrequently finds +a mediocre man; and often, even in a mediocre artist, one finds a very +remarkable man. + +138. We do the same when awake as when dreaming: we only invent and +imagine him with whom we have intercourse--and forget it immediately. + +139. In revenge and in love woman is more barbarous than man. + +140. ADVICE AS A RIDDLE.--"If the band is not to break, bite it +first--secure to make!" + +141. The belly is the reason why man does not so readily take himself +for a God. + +142. The chastest utterance I ever heard: "Dans le veritable amour c'est +l'ame qui enveloppe le corps." + +143. Our vanity would like what we do best to pass precisely for what is +most difficult to us.--Concerning the origin of many systems of morals. + +144. When a woman has scholarly inclinations there is generally +something wrong with her sexual nature. Barrenness itself conduces to a +certain virility of taste; man, indeed, if I may say so, is "the barren +animal." + +145. Comparing man and woman generally, one may say that woman would +not have the genius for adornment, if she had not the instinct for the +SECONDARY role. + +146. He who fights with monsters should be careful lest he thereby +become a monster. And if thou gaze long into an abyss, the abyss will +also gaze into thee. + +147. From old Florentine novels--moreover, from life: Buona femmina e +mala femmina vuol bastone.--Sacchetti, Nov. 86. + +148. To seduce their neighbour to a favourable opinion, and afterwards +to believe implicitly in this opinion of their neighbour--who can do +this conjuring trick so well as women? + +149. That which an age considers evil is usually an unseasonable echo of +what was formerly considered good--the atavism of an old ideal. + +150. Around the hero everything becomes a tragedy; around the +demigod everything becomes a satyr-play; and around God everything +becomes--what? perhaps a "world"? + +151. It is not enough to possess a talent: one must also have your +permission to possess it;--eh, my friends? + +152. "Where there is the tree of knowledge, there is always Paradise": +so say the most ancient and the most modern serpents. + +153. What is done out of love always takes place beyond good and evil. + +154. Objection, evasion, joyous distrust, and love of irony are signs of +health; everything absolute belongs to pathology. + +155. The sense of the tragic increases and declines with sensuousness. + +156. Insanity in individuals is something rare--but in groups, parties, +nations, and epochs it is the rule. + +157. The thought of suicide is a great consolation: by means of it one +gets successfully through many a bad night. + +158. Not only our reason, but also our conscience, truckles to our +strongest impulse--the tyrant in us. + +159. One MUST repay good and ill; but why just to the person who did us +good or ill? + +160. One no longer loves one's knowledge sufficiently after one has +communicated it. + +161. Poets act shamelessly towards their experiences: they exploit them. + +162. "Our fellow-creature is not our neighbour, but our neighbour's +neighbour":--so thinks every nation. + +163. Love brings to light the noble and hidden qualities of a lover--his +rare and exceptional traits: it is thus liable to be deceptive as to his +normal character. + +164. Jesus said to his Jews: "The law was for servants;--love God as I +love him, as his Son! What have we Sons of God to do with morals!" + +165. IN SIGHT OF EVERY PARTY.--A shepherd has always need of a +bell-wether--or he has himself to be a wether occasionally. + +166. One may indeed lie with the mouth; but with the accompanying +grimace one nevertheless tells the truth. + +167. To vigorous men intimacy is a matter of shame--and something +precious. + +168. Christianity gave Eros poison to drink; he did not die of it, +certainly, but degenerated to Vice. + +169. To talk much about oneself may also be a means of concealing +oneself. + +170. In praise there is more obtrusiveness than in blame. + +171. Pity has an almost ludicrous effect on a man of knowledge, like +tender hands on a Cyclops. + +172. One occasionally embraces some one or other, out of love to mankind +(because one cannot embrace all); but this is what one must never +confess to the individual. + +173. One does not hate as long as one disesteems, but only when one +esteems equal or superior. + +174. Ye Utilitarians--ye, too, love the UTILE only as a VEHICLE for +your inclinations,--ye, too, really find the noise of its wheels +insupportable! + +175. One loves ultimately one's desires, not the thing desired. + +176. The vanity of others is only counter to our taste when it is +counter to our vanity. + +177. With regard to what "truthfulness" is, perhaps nobody has ever been +sufficiently truthful. + +178. One does not believe in the follies of clever men: what a +forfeiture of the rights of man! + +179. The consequences of our actions seize us by the forelock, very +indifferent to the fact that we have meanwhile "reformed." + +180. There is an innocence in lying which is the sign of good faith in a +cause. + +181. It is inhuman to bless when one is being cursed. + +182. The familiarity of superiors embitters one, because it may not be +returned. + +183. "I am affected, not because you have deceived me, but because I can +no longer believe in you." + +184. There is a haughtiness of kindness which has the appearance of +wickedness. + +185. "I dislike him."--Why?--"I am not a match for him."--Did any one +ever answer so? + + + +CHAPTER V. THE NATURAL HISTORY OF MORALS + + +186. The moral sentiment in Europe at present is perhaps as subtle, +belated, diverse, sensitive, and refined, as the "Science of Morals" +belonging thereto is recent, initial, awkward, and coarse-fingered:--an +interesting contrast, which sometimes becomes incarnate and obvious +in the very person of a moralist. Indeed, the expression, "Science +of Morals" is, in respect to what is designated thereby, far too +presumptuous and counter to GOOD taste,--which is always a foretaste of +more modest expressions. One ought to avow with the utmost fairness WHAT +is still necessary here for a long time, WHAT is alone proper for the +present: namely, the collection of material, the comprehensive survey +and classification of an immense domain of delicate sentiments of worth, +and distinctions of worth, which live, grow, propagate, and perish--and +perhaps attempts to give a clear idea of the recurring and more common +forms of these living crystallizations--as preparation for a THEORY OF +TYPES of morality. To be sure, people have not hitherto been so modest. +All the philosophers, with a pedantic and ridiculous seriousness, +demanded of themselves something very much higher, more pretentious, and +ceremonious, when they concerned themselves with morality as a science: +they wanted to GIVE A BASIC to morality--and every philosopher hitherto +has believed that he has given it a basis; morality itself, however, has +been regarded as something "given." How far from their awkward pride +was the seemingly insignificant problem--left in dust and decay--of a +description of forms of morality, notwithstanding that the finest hands +and senses could hardly be fine enough for it! It was precisely owing to +moral philosophers' knowing the moral facts imperfectly, in an arbitrary +epitome, or an accidental abridgement--perhaps as the morality of +their environment, their position, their church, their Zeitgeist, their +climate and zone--it was precisely because they were badly instructed +with regard to nations, eras, and past ages, and were by no means eager +to know about these matters, that they did not even come in sight of the +real problems of morals--problems which only disclose themselves by +a comparison of MANY kinds of morality. In every "Science of Morals" +hitherto, strange as it may sound, the problem of morality itself +has been OMITTED: there has been no suspicion that there was anything +problematic there! That which philosophers called "giving a basis to +morality," and endeavoured to realize, has, when seen in a right light, +proved merely a learned form of good FAITH in prevailing morality, a new +means of its EXPRESSION, consequently just a matter-of-fact within the +sphere of a definite morality, yea, in its ultimate motive, a sort of +denial that it is LAWFUL for this morality to be called in question--and +in any case the reverse of the testing, analyzing, doubting, and +vivisecting of this very faith. Hear, for instance, with what +innocence--almost worthy of honour--Schopenhauer represents his own +task, and draw your conclusions concerning the scientificness of a +"Science" whose latest master still talks in the strain of children and +old wives: "The principle," he says (page 136 of the Grundprobleme der +Ethik), [Footnote: Pages 54-55 of Schopenhauer's Basis of Morality, +translated by Arthur B. Bullock, M.A. (1903).] "the axiom about the +purport of which all moralists are PRACTICALLY agreed: neminem laede, +immo omnes quantum potes juva--is REALLY the proposition which all moral +teachers strive to establish, ... the REAL basis of ethics which +has been sought, like the philosopher's stone, for centuries."--The +difficulty of establishing the proposition referred to may indeed be +great--it is well known that Schopenhauer also was unsuccessful in his +efforts; and whoever has thoroughly realized how absurdly false and +sentimental this proposition is, in a world whose essence is Will +to Power, may be reminded that Schopenhauer, although a pessimist, +ACTUALLY--played the flute... daily after dinner: one may read about +the matter in his biography. A question by the way: a pessimist, a +repudiator of God and of the world, who MAKES A HALT at morality--who +assents to morality, and plays the flute to laede-neminem morals, what? +Is that really--a pessimist? + +187. Apart from the value of such assertions as "there is a categorical +imperative in us," one can always ask: What does such an assertion +indicate about him who makes it? There are systems of morals which are +meant to justify their author in the eyes of other people; other systems +of morals are meant to tranquilize him, and make him self-satisfied; +with other systems he wants to crucify and humble himself, with others +he wishes to take revenge, with others to conceal himself, with others +to glorify himself and gave superiority and distinction,--this system of +morals helps its author to forget, that system makes him, or something +of him, forgotten, many a moralist would like to exercise power and +creative arbitrariness over mankind, many another, perhaps, Kant +especially, gives us to understand by his morals that "what is estimable +in me, is that I know how to obey--and with you it SHALL not be +otherwise than with me!" In short, systems of morals are only a +SIGN-LANGUAGE OF THE EMOTIONS. + +188. In contrast to laisser-aller, every system of morals is a sort of +tyranny against "nature" and also against "reason", that is, however, no +objection, unless one should again decree by some system of morals, that +all kinds of tyranny and unreasonableness are unlawful What is +essential and invaluable in every system of morals, is that it is a +long constraint. In order to understand Stoicism, or Port Royal, +or Puritanism, one should remember the constraint under which every +language has attained to strength and freedom--the metrical constraint, +the tyranny of rhyme and rhythm. How much trouble have the poets and +orators of every nation given themselves!--not excepting some of +the prose writers of today, in whose ear dwells an inexorable +conscientiousness--"for the sake of a folly," as utilitarian bunglers +say, and thereby deem themselves wise--"from submission to arbitrary +laws," as the anarchists say, and thereby fancy themselves "free," even +free-spirited. The singular fact remains, however, that everything +of the nature of freedom, elegance, boldness, dance, and masterly +certainty, which exists or has existed, whether it be in thought itself, +or in administration, or in speaking and persuading, in art just as in +conduct, has only developed by means of the tyranny of such arbitrary +law, and in all seriousness, it is not at all improbable that precisely +this is "nature" and "natural"--and not laisser-aller! Every artist +knows how different from the state of letting himself go, is his +"most natural" condition, the free arranging, locating, disposing, +and constructing in the moments of "inspiration"--and how strictly and +delicately he then obeys a thousand laws, which, by their very rigidness +and precision, defy all formulation by means of ideas (even the most +stable idea has, in comparison therewith, something floating, manifold, +and ambiguous in it). The essential thing "in heaven and in earth" is, +apparently (to repeat it once more), that there should be long OBEDIENCE +in the same direction, there thereby results, and has always resulted in +the long run, something which has made life worth living; for instance, +virtue, art, music, dancing, reason, spirituality--anything whatever +that is transfiguring, refined, foolish, or divine. The long bondage of +the spirit, the distrustful constraint in the communicability of +ideas, the discipline which the thinker imposed on himself to think +in accordance with the rules of a church or a court, or conformable +to Aristotelian premises, the persistent spiritual will to interpret +everything that happened according to a Christian scheme, and in every +occurrence to rediscover and justify the Christian God:--all this +violence, arbitrariness, severity, dreadfulness, and unreasonableness, +has proved itself the disciplinary means whereby the European spirit has +attained its strength, its remorseless curiosity and subtle mobility; +granted also that much irrecoverable strength and spirit had to be +stifled, suffocated, and spoilt in the process (for here, as everywhere, +"nature" shows herself as she is, in all her extravagant and INDIFFERENT +magnificence, which is shocking, but nevertheless noble). That +for centuries European thinkers only thought in order to prove +something--nowadays, on the contrary, we are suspicious of every thinker +who "wishes to prove something"--that it was always settled beforehand +what WAS TO BE the result of their strictest thinking, as it was perhaps +in the Asiatic astrology of former times, or as it is still at the +present day in the innocent, Christian-moral explanation of immediate +personal events "for the glory of God," or "for the good of the +soul":--this tyranny, this arbitrariness, this severe and magnificent +stupidity, has EDUCATED the spirit; slavery, both in the coarser and +the finer sense, is apparently an indispensable means even of spiritual +education and discipline. One may look at every system of morals in this +light: it is "nature" therein which teaches to hate the laisser-aller, +the too great freedom, and implants the need for limited horizons, for +immediate duties--it teaches the NARROWING OF PERSPECTIVES, and thus, in +a certain sense, that stupidity is a condition of life and development. +"Thou must obey some one, and for a long time; OTHERWISE thou wilt come +to grief, and lose all respect for thyself"--this seems to me to be the +moral imperative of nature, which is certainly neither "categorical," +as old Kant wished (consequently the "otherwise"), nor does it address +itself to the individual (what does nature care for the individual!), +but to nations, races, ages, and ranks; above all, however, to the +animal "man" generally, to MANKIND. + +189. Industrious races find it a great hardship to be idle: it was a +master stroke of ENGLISH instinct to hallow and begloom Sunday to such +an extent that the Englishman unconsciously hankers for his week--and +work-day again:--as a kind of cleverly devised, cleverly intercalated +FAST, such as is also frequently found in the ancient world (although, +as is appropriate in southern nations, not precisely with respect +to work). Many kinds of fasts are necessary; and wherever powerful +influences and habits prevail, legislators have to see that intercalary +days are appointed, on which such impulses are fettered, and learn to +hunger anew. Viewed from a higher standpoint, whole generations and +epochs, when they show themselves infected with any moral fanaticism, +seem like those intercalated periods of restraint and fasting, during +which an impulse learns to humble and submit itself--at the same time +also to PURIFY and SHARPEN itself; certain philosophical sects likewise +admit of a similar interpretation (for instance, the Stoa, in the midst +of Hellenic culture, with the atmosphere rank and overcharged with +Aphrodisiacal odours).--Here also is a hint for the explanation of the +paradox, why it was precisely in the most Christian period of European +history, and in general only under the pressure of Christian sentiments, +that the sexual impulse sublimated into love (amour-passion). + +190. There is something in the morality of Plato which does not really +belong to Plato, but which only appears in his philosophy, one might +say, in spite of him: namely, Socratism, for which he himself was +too noble. "No one desires to injure himself, hence all evil is done +unwittingly. The evil man inflicts injury on himself; he would not do +so, however, if he knew that evil is evil. The evil man, therefore, is +only evil through error; if one free him from error one will necessarily +make him--good."--This mode of reasoning savours of the POPULACE, who +perceive only the unpleasant consequences of evil-doing, and practically +judge that "it is STUPID to do wrong"; while they accept "good" as +identical with "useful and pleasant," without further thought. As +regards every system of utilitarianism, one may at once assume that it +has the same origin, and follow the scent: one will seldom err.--Plato +did all he could to interpret something refined and noble into the +tenets of his teacher, and above all to interpret himself into them--he, +the most daring of all interpreters, who lifted the entire Socrates out +of the street, as a popular theme and song, to exhibit him in endless +and impossible modifications--namely, in all his own disguises and +multiplicities. In jest, and in Homeric language as well, what is the +Platonic Socrates, if not--[Greek words inserted here.] + +191. The old theological problem of "Faith" and "Knowledge," or more +plainly, of instinct and reason--the question whether, in respect to the +valuation of things, instinct deserves more authority than rationality, +which wants to appreciate and act according to motives, according to +a "Why," that is to say, in conformity to purpose and utility--it +is always the old moral problem that first appeared in the person of +Socrates, and had divided men's minds long before Christianity. Socrates +himself, following, of course, the taste of his talent--that of a +surpassing dialectician--took first the side of reason; and, in fact, +what did he do all his life but laugh at the awkward incapacity of the +noble Athenians, who were men of instinct, like all noble men, and could +never give satisfactory answers concerning the motives of their actions? +In the end, however, though silently and secretly, he laughed also +at himself: with his finer conscience and introspection, he found +in himself the same difficulty and incapacity. "But why"--he said +to himself--"should one on that account separate oneself from the +instincts! One must set them right, and the reason ALSO--one must follow +the instincts, but at the same time persuade the reason to support them +with good arguments." This was the real FALSENESS of that great and +mysterious ironist; he brought his conscience up to the point that he +was satisfied with a kind of self-outwitting: in fact, he perceived +the irrationality in the moral judgment.--Plato, more innocent in such +matters, and without the craftiness of the plebeian, wished to prove to +himself, at the expenditure of all his strength--the greatest strength +a philosopher had ever expended--that reason and instinct lead +spontaneously to one goal, to the good, to "God"; and since Plato, all +theologians and philosophers have followed the same path--which means +that in matters of morality, instinct (or as Christians call it, +"Faith," or as I call it, "the herd") has hitherto triumphed. Unless +one should make an exception in the case of Descartes, the father of +rationalism (and consequently the grandfather of the Revolution), who +recognized only the authority of reason: but reason is only a tool, and +Descartes was superficial. + +192. Whoever has followed the history of a single science, finds in +its development a clue to the understanding of the oldest and commonest +processes of all "knowledge and cognizance": there, as here, the +premature hypotheses, the fictions, the good stupid will to "belief," +and the lack of distrust and patience are first developed--our senses +learn late, and never learn completely, to be subtle, reliable, and +cautious organs of knowledge. Our eyes find it easier on a given +occasion to produce a picture already often produced, than to seize upon +the divergence and novelty of an impression: the latter requires more +force, more "morality." It is difficult and painful for the ear to +listen to anything new; we hear strange music badly. When we hear +another language spoken, we involuntarily attempt to form the sounds +into words with which we are more familiar and conversant--it was thus, +for example, that the Germans modified the spoken word ARCUBALISTA into +ARMBRUST (cross-bow). Our senses are also hostile and averse to the +new; and generally, even in the "simplest" processes of sensation, the +emotions DOMINATE--such as fear, love, hatred, and the passive emotion +of indolence.--As little as a reader nowadays reads all the single words +(not to speak of syllables) of a page--he rather takes about five out +of every twenty words at random, and "guesses" the probably appropriate +sense to them--just as little do we see a tree correctly and completely +in respect to its leaves, branches, colour, and shape; we find it so +much easier to fancy the chance of a tree. Even in the midst of the +most remarkable experiences, we still do just the same; we fabricate the +greater part of the experience, and can hardly be made to contemplate +any event, EXCEPT as "inventors" thereof. All this goes to prove +that from our fundamental nature and from remote ages we have +been--ACCUSTOMED TO LYING. Or, to express it more politely and +hypocritically, in short, more pleasantly--one is much more of an artist +than one is aware of.--In an animated conversation, I often see the face +of the person with whom I am speaking so clearly and sharply defined +before me, according to the thought he expresses, or which I believe to +be evoked in his mind, that the degree of distinctness far exceeds the +STRENGTH of my visual faculty--the delicacy of the play of the muscles +and of the expression of the eyes MUST therefore be imagined by me. +Probably the person put on quite a different expression, or none at all. + +193. Quidquid luce fuit, tenebris agit: but also contrariwise. What we +experience in dreams, provided we experience it often, pertains at +last just as much to the general belongings of our soul as anything +"actually" experienced; by virtue thereof we are richer or poorer, we +have a requirement more or less, and finally, in broad daylight, and +even in the brightest moments of our waking life, we are ruled to some +extent by the nature of our dreams. Supposing that someone has often +flown in his dreams, and that at last, as soon as he dreams, he is +conscious of the power and art of flying as his privilege and his +peculiarly enviable happiness; such a person, who believes that on the +slightest impulse, he can actualize all sorts of curves and angles, who +knows the sensation of a certain divine levity, an "upwards" +without effort or constraint, a "downwards" without descending +or lowering--without TROUBLE!--how could the man with such +dream-experiences and dream-habits fail to find "happiness" differently +coloured and defined, even in his waking hours! How could he fail--to +long DIFFERENTLY for happiness? "Flight," such as is described by poets, +must, when compared with his own "flying," be far too earthly, muscular, +violent, far too "troublesome" for him. + +194. The difference among men does not manifest itself only in the +difference of their lists of desirable things--in their regarding +different good things as worth striving for, and being disagreed as to +the greater or less value, the order of rank, of the commonly recognized +desirable things:--it manifests itself much more in what they regard as +actually HAVING and POSSESSING a desirable thing. As regards a woman, +for instance, the control over her body and her sexual gratification +serves as an amply sufficient sign of ownership and possession to the +more modest man; another with a more suspicious and ambitious thirst for +possession, sees the "questionableness," the mere apparentness of such +ownership, and wishes to have finer tests in order to know especially +whether the woman not only gives herself to him, but also gives up for +his sake what she has or would like to have--only THEN does he look upon +her as "possessed." A third, however, has not even here got to the limit +of his distrust and his desire for possession: he asks himself whether +the woman, when she gives up everything for him, does not perhaps do +so for a phantom of him; he wishes first to be thoroughly, indeed, +profoundly well known; in order to be loved at all he ventures to let +himself be found out. Only then does he feel the beloved one fully in +his possession, when she no longer deceives herself about him, when +she loves him just as much for the sake of his devilry and concealed +insatiability, as for his goodness, patience, and spirituality. One +man would like to possess a nation, and he finds all the higher arts of +Cagliostro and Catalina suitable for his purpose. Another, with a more +refined thirst for possession, says to himself: "One may not deceive +where one desires to possess"--he is irritated and impatient at the idea +that a mask of him should rule in the hearts of the people: "I must, +therefore, MAKE myself known, and first of all learn to know myself!" +Among helpful and charitable people, one almost always finds the awkward +craftiness which first gets up suitably him who has to be helped, as +though, for instance, he should "merit" help, seek just THEIR help, and +would show himself deeply grateful, attached, and subservient to them +for all help. With these conceits, they take control of the needy as a +property, just as in general they are charitable and helpful out of a +desire for property. One finds them jealous when they are crossed or +forestalled in their charity. Parents involuntarily make something like +themselves out of their children--they call that "education"; no mother +doubts at the bottom of her heart that the child she has borne is +thereby her property, no father hesitates about his right to HIS OWN +ideas and notions of worth. Indeed, in former times fathers deemed it +right to use their discretion concerning the life or death of the newly +born (as among the ancient Germans). And like the father, so also do the +teacher, the class, the priest, and the prince still see in every new +individual an unobjectionable opportunity for a new possession. The +consequence is... + +195. The Jews--a people "born for slavery," as Tacitus and the whole +ancient world say of them; "the chosen people among the nations," as +they themselves say and believe--the Jews performed the miracle of the +inversion of valuations, by means of which life on earth obtained a new +and dangerous charm for a couple of millenniums. Their prophets fused +into one the expressions "rich," "godless," "wicked," "violent," +"sensual," and for the first time coined the word "world" as a term of +reproach. In this inversion of valuations (in which is also included +the use of the word "poor" as synonymous with "saint" and "friend") the +significance of the Jewish people is to be found; it is with THEM that +the SLAVE-INSURRECTION IN MORALS commences. + +196. It is to be INFERRED that there are countless dark bodies near the +sun--such as we shall never see. Among ourselves, this is an allegory; +and the psychologist of morals reads the whole star-writing merely as an +allegorical and symbolic language in which much may be unexpressed. + +197. The beast of prey and the man of prey (for instance, Caesar Borgia) +are fundamentally misunderstood, "nature" is misunderstood, so long as +one seeks a "morbidness" in the constitution of these healthiest of +all tropical monsters and growths, or even an innate "hell" in them--as +almost all moralists have done hitherto. Does it not seem that there is +a hatred of the virgin forest and of the tropics among moralists? And +that the "tropical man" must be discredited at all costs, whether +as disease and deterioration of mankind, or as his own hell and +self-torture? And why? In favour of the "temperate zones"? In favour +of the temperate men? The "moral"? The mediocre?--This for the chapter: +"Morals as Timidity." + +198. All the systems of morals which address themselves with a view to +their "happiness," as it is called--what else are they but suggestions +for behaviour adapted to the degree of DANGER from themselves in which +the individuals live; recipes for their passions, their good and bad +propensities, insofar as such have the Will to Power and would like +to play the master; small and great expediencies and elaborations, +permeated with the musty odour of old family medicines and old-wife +wisdom; all of them grotesque and absurd in their form--because +they address themselves to "all," because they generalize where +generalization is not authorized; all of them speaking unconditionally, +and taking themselves unconditionally; all of them flavoured not merely +with one grain of salt, but rather endurable only, and sometimes even +seductive, when they are over-spiced and begin to smell dangerously, +especially of "the other world." That is all of little value when +estimated intellectually, and is far from being "science," much less +"wisdom"; but, repeated once more, and three times repeated, it is +expediency, expediency, expediency, mixed with stupidity, stupidity, +stupidity--whether it be the indifference and statuesque coldness +towards the heated folly of the emotions, which the Stoics advised and +fostered; or the no-more-laughing and no-more-weeping of Spinoza, the +destruction of the emotions by their analysis and vivisection, which he +recommended so naively; or the lowering of the emotions to an innocent +mean at which they may be satisfied, the Aristotelianism of morals; +or even morality as the enjoyment of the emotions in a voluntary +attenuation and spiritualization by the symbolism of art, perhaps as +music, or as love of God, and of mankind for God's sake--for in religion +the passions are once more enfranchised, provided that...; or, finally, +even the complaisant and wanton surrender to the emotions, as has +been taught by Hafis and Goethe, the bold letting-go of the reins, the +spiritual and corporeal licentia morum in the exceptional cases of +wise old codgers and drunkards, with whom it "no longer has much +danger."--This also for the chapter: "Morals as Timidity." + +199. Inasmuch as in all ages, as long as mankind has existed, there have +also been human herds (family alliances, communities, tribes, peoples, +states, churches), and always a great number who obey in proportion +to the small number who command--in view, therefore, of the fact that +obedience has been most practiced and fostered among mankind hitherto, +one may reasonably suppose that, generally speaking, the need thereof is +now innate in every one, as a kind of FORMAL CONSCIENCE which gives +the command "Thou shalt unconditionally do something, unconditionally +refrain from something", in short, "Thou shalt". This need tries to +satisfy itself and to fill its form with a content, according to its +strength, impatience, and eagerness, it at once seizes as an omnivorous +appetite with little selection, and accepts whatever is shouted into +its ear by all sorts of commanders--parents, teachers, laws, class +prejudices, or public opinion. The extraordinary limitation of human +development, the hesitation, protractedness, frequent retrogression, and +turning thereof, is attributable to the fact that the herd-instinct of +obedience is transmitted best, and at the cost of the art of command. If +one imagine this instinct increasing to its greatest extent, commanders +and independent individuals will finally be lacking altogether, or they +will suffer inwardly from a bad conscience, and will have to impose +a deception on themselves in the first place in order to be able to +command just as if they also were only obeying. This condition of things +actually exists in Europe at present--I call it the moral hypocrisy of +the commanding class. They know no other way of protecting themselves +from their bad conscience than by playing the role of executors of older +and higher orders (of predecessors, of the constitution, of justice, of +the law, or of God himself), or they even justify themselves by maxims +from the current opinions of the herd, as "first servants of their +people," or "instruments of the public weal". On the other hand, the +gregarious European man nowadays assumes an air as if he were the only +kind of man that is allowable, he glorifies his qualities, such as +public spirit, kindness, deference, industry, temperance, modesty, +indulgence, sympathy, by virtue of which he is gentle, endurable, and +useful to the herd, as the peculiarly human virtues. In cases, however, +where it is believed that the leader and bell-wether cannot be dispensed +with, attempt after attempt is made nowadays to replace commanders +by the summing together of clever gregarious men all representative +constitutions, for example, are of this origin. In spite of all, what a +blessing, what a deliverance from a weight becoming unendurable, is the +appearance of an absolute ruler for these gregarious Europeans--of this +fact the effect of the appearance of Napoleon was the last great proof +the history of the influence of Napoleon is almost the history of +the higher happiness to which the entire century has attained in its +worthiest individuals and periods. + +200. The man of an age of dissolution which mixes the races with +one another, who has the inheritance of a diversified descent in his +body--that is to say, contrary, and often not only contrary, instincts +and standards of value, which struggle with one another and are seldom +at peace--such a man of late culture and broken lights, will, on an +average, be a weak man. His fundamental desire is that the war which is +IN HIM should come to an end; happiness appears to him in the character +of a soothing medicine and mode of thought (for instance, Epicurean +or Christian); it is above all things the happiness of repose, of +undisturbedness, of repletion, of final unity--it is the "Sabbath of +Sabbaths," to use the expression of the holy rhetorician, St. Augustine, +who was himself such a man.--Should, however, the contrariety and +conflict in such natures operate as an ADDITIONAL incentive and stimulus +to life--and if, on the other hand, in addition to their powerful and +irreconcilable instincts, they have also inherited and indoctrinated +into them a proper mastery and subtlety for carrying on the conflict +with themselves (that is to say, the faculty of self-control and +self-deception), there then arise those marvelously incomprehensible and +inexplicable beings, those enigmatical men, predestined for conquering +and circumventing others, the finest examples of which are Alcibiades +and Caesar (with whom I should like to associate the FIRST of Europeans +according to my taste, the Hohenstaufen, Frederick the Second), and +among artists, perhaps Leonardo da Vinci. They appear precisely in the +same periods when that weaker type, with its longing for repose, comes +to the front; the two types are complementary to each other, and spring +from the same causes. + +201. As long as the utility which determines moral estimates is only +gregarious utility, as long as the preservation of the community is only +kept in view, and the immoral is sought precisely and exclusively in +what seems dangerous to the maintenance of the community, there can be +no "morality of love to one's neighbour." Granted even that there is +already a little constant exercise of consideration, sympathy, fairness, +gentleness, and mutual assistance, granted that even in this condition +of society all those instincts are already active which are latterly +distinguished by honourable names as "virtues," and eventually almost +coincide with the conception "morality": in that period they do not +as yet belong to the domain of moral valuations--they are still +ULTRA-MORAL. A sympathetic action, for instance, is neither called good +nor bad, moral nor immoral, in the best period of the Romans; and should +it be praised, a sort of resentful disdain is compatible with this +praise, even at the best, directly the sympathetic action is compared +with one which contributes to the welfare of the whole, to the RES +PUBLICA. After all, "love to our neighbour" is always a secondary +matter, partly conventional and arbitrarily manifested in relation to +our FEAR OF OUR NEIGHBOUR. After the fabric of society seems on the +whole established and secured against external dangers, it is this +fear of our neighbour which again creates new perspectives of moral +valuation. Certain strong and dangerous instincts, such as the love of +enterprise, foolhardiness, revengefulness, astuteness, rapacity, and +love of power, which up till then had not only to be honoured from the +point of view of general utility--under other names, of course, than +those here given--but had to be fostered and cultivated (because they +were perpetually required in the common danger against the common +enemies), are now felt in their dangerousness to be doubly strong--when +the outlets for them are lacking--and are gradually branded as immoral +and given over to calumny. The contrary instincts and inclinations now +attain to moral honour, the gregarious instinct gradually draws its +conclusions. How much or how little dangerousness to the community or +to equality is contained in an opinion, a condition, an emotion, a +disposition, or an endowment--that is now the moral perspective, here +again fear is the mother of morals. It is by the loftiest and strongest +instincts, when they break out passionately and carry the individual +far above and beyond the average, and the low level of the gregarious +conscience, that the self-reliance of the community is destroyed, its +belief in itself, its backbone, as it were, breaks, consequently these +very instincts will be most branded and defamed. The lofty independent +spirituality, the will to stand alone, and even the cogent reason, are +felt to be dangers, everything that elevates the individual above the +herd, and is a source of fear to the neighbour, is henceforth called +EVIL, the tolerant, unassuming, self-adapting, self-equalizing +disposition, the MEDIOCRITY of desires, attains to moral distinction and +honour. Finally, under very peaceful circumstances, there is always +less opportunity and necessity for training the feelings to severity +and rigour, and now every form of severity, even in justice, begins +to disturb the conscience, a lofty and rigorous nobleness and +self-responsibility almost offends, and awakens distrust, "the lamb," +and still more "the sheep," wins respect. There is a point of diseased +mellowness and effeminacy in the history of society, at which society +itself takes the part of him who injures it, the part of the CRIMINAL, +and does so, in fact, seriously and honestly. To punish, appears to it +to be somehow unfair--it is certain that the idea of "punishment" and +"the obligation to punish" are then painful and alarming to people. "Is +it not sufficient if the criminal be rendered HARMLESS? Why should we +still punish? Punishment itself is terrible!"--with these questions +gregarious morality, the morality of fear, draws its ultimate +conclusion. If one could at all do away with danger, the cause of fear, +one would have done away with this morality at the same time, it +would no longer be necessary, it WOULD NOT CONSIDER ITSELF any longer +necessary!--Whoever examines the conscience of the present-day European, +will always elicit the same imperative from its thousand moral folds +and hidden recesses, the imperative of the timidity of the herd "we wish +that some time or other there may be NOTHING MORE TO FEAR!" Some time +or other--the will and the way THERETO is nowadays called "progress" all +over Europe. + +202. Let us at once say again what we have already said a hundred +times, for people's ears nowadays are unwilling to hear such truths--OUR +truths. We know well enough how offensive it sounds when any one +plainly, and without metaphor, counts man among the animals, but it will +be accounted to us almost a CRIME, that it is precisely in respect to +men of "modern ideas" that we have constantly applied the terms "herd," +"herd-instincts," and such like expressions. What avail is it? We cannot +do otherwise, for it is precisely here that our new insight is. We +have found that in all the principal moral judgments, Europe has become +unanimous, including likewise the countries where European influence +prevails in Europe people evidently KNOW what Socrates thought he +did not know, and what the famous serpent of old once promised to +teach--they "know" today what is good and evil. It must then sound hard +and be distasteful to the ear, when we always insist that that which +here thinks it knows, that which here glorifies itself with praise +and blame, and calls itself good, is the instinct of the herding human +animal, the instinct which has come and is ever coming more and more +to the front, to preponderance and supremacy over other instincts, +according to the increasing physiological approximation and resemblance +of which it is the symptom. MORALITY IN EUROPE AT PRESENT IS +HERDING-ANIMAL MORALITY, and therefore, as we understand the matter, +only one kind of human morality, beside which, before which, and after +which many other moralities, and above all HIGHER moralities, are or +should be possible. Against such a "possibility," against such a "should +be," however, this morality defends itself with all its strength, it +says obstinately and inexorably "I am morality itself and nothing else +is morality!" Indeed, with the help of a religion which has humoured +and flattered the sublimest desires of the herding-animal, things have +reached such a point that we always find a more visible expression of +this morality even in political and social arrangements: the DEMOCRATIC +movement is the inheritance of the Christian movement. That its TEMPO, +however, is much too slow and sleepy for the more impatient ones, for +those who are sick and distracted by the herding-instinct, is indicated +by the increasingly furious howling, and always less disguised +teeth-gnashing of the anarchist dogs, who are now roving through the +highways of European culture. Apparently in opposition to the peacefully +industrious democrats and Revolution-ideologues, and still more so +to the awkward philosophasters and fraternity-visionaries who call +themselves Socialists and want a "free society," those are really at one +with them all in their thorough and instinctive hostility to every form +of society other than that of the AUTONOMOUS herd (to the extent even of +repudiating the notions "master" and "servant"--ni dieu ni maitre, says +a socialist formula); at one in their tenacious opposition to every +special claim, every special right and privilege (this means ultimately +opposition to EVERY right, for when all are equal, no one needs "rights" +any longer); at one in their distrust of punitive justice (as though it +were a violation of the weak, unfair to the NECESSARY consequences of +all former society); but equally at one in their religion of sympathy, +in their compassion for all that feels, lives, and suffers (down to the +very animals, up even to "God"--the extravagance of "sympathy for +God" belongs to a democratic age); altogether at one in the cry and +impatience of their sympathy, in their deadly hatred of suffering +generally, in their almost feminine incapacity for witnessing it or +ALLOWING it; at one in their involuntary beglooming and heart-softening, +under the spell of which Europe seems to be threatened with a new +Buddhism; at one in their belief in the morality of MUTUAL sympathy, as +though it were morality in itself, the climax, the ATTAINED climax of +mankind, the sole hope of the future, the consolation of the present, +the great discharge from all the obligations of the past; altogether at +one in their belief in the community as the DELIVERER, in the herd, and +therefore in "themselves." + +203. We, who hold a different belief--we, who regard the democratic +movement, not only as a degenerating form of political organization, but +as equivalent to a degenerating, a waning type of man, as involving his +mediocrising and depreciation: where have WE to fix our hopes? In +NEW PHILOSOPHERS--there is no other alternative: in minds strong and +original enough to initiate opposite estimates of value, to transvalue +and invert "eternal valuations"; in forerunners, in men of the future, +who in the present shall fix the constraints and fasten the knots which +will compel millenniums to take NEW paths. To teach man the future +of humanity as his WILL, as depending on human will, and to make +preparation for vast hazardous enterprises and collective attempts in +rearing and educating, in order thereby to put an end to the frightful +rule of folly and chance which has hitherto gone by the name of +"history" (the folly of the "greatest number" is only its last +form)--for that purpose a new type of philosopher and commander will +some time or other be needed, at the very idea of which everything that +has existed in the way of occult, terrible, and benevolent beings might +look pale and dwarfed. The image of such leaders hovers before OUR +eyes:--is it lawful for me to say it aloud, ye free spirits? The +conditions which one would partly have to create and partly utilize for +their genesis; the presumptive methods and tests by virtue of which +a soul should grow up to such an elevation and power as to feel a +CONSTRAINT to these tasks; a transvaluation of values, under the new +pressure and hammer of which a conscience should be steeled and a heart +transformed into brass, so as to bear the weight of such responsibility; +and on the other hand the necessity for such leaders, the dreadful +danger that they might be lacking, or miscarry and degenerate:--these +are OUR real anxieties and glooms, ye know it well, ye free spirits! +these are the heavy distant thoughts and storms which sweep across the +heaven of OUR life. There are few pains so grievous as to have seen, +divined, or experienced how an exceptional man has missed his way and +deteriorated; but he who has the rare eye for the universal danger +of "man" himself DETERIORATING, he who like us has recognized the +extraordinary fortuitousness which has hitherto played its game in +respect to the future of mankind--a game in which neither the hand, nor +even a "finger of God" has participated!--he who divines the fate that +is hidden under the idiotic unwariness and blind confidence of +"modern ideas," and still more under the whole of Christo-European +morality--suffers from an anguish with which no other is to be compared. +He sees at a glance all that could still BE MADE OUT OF MAN through +a favourable accumulation and augmentation of human powers and +arrangements; he knows with all the knowledge of his conviction how +unexhausted man still is for the greatest possibilities, and how often +in the past the type man has stood in presence of mysterious decisions +and new paths:--he knows still better from his painfulest recollections +on what wretched obstacles promising developments of the highest rank +have hitherto usually gone to pieces, broken down, sunk, and become +contemptible. The UNIVERSAL DEGENERACY OF MANKIND to the level of +the "man of the future"--as idealized by the socialistic fools and +shallow-pates--this degeneracy and dwarfing of man to an absolutely +gregarious animal (or as they call it, to a man of "free society"), +this brutalizing of man into a pigmy with equal rights and claims, is +undoubtedly POSSIBLE! He who has thought out this possibility to its +ultimate conclusion knows ANOTHER loathing unknown to the rest of +mankind--and perhaps also a new MISSION! + + + +CHAPTER VI. WE SCHOLARS + + +204. At the risk that moralizing may also reveal itself here as that +which it has always been--namely, resolutely MONTRER SES PLAIES, +according to Balzac--I would venture to protest against an improper and +injurious alteration of rank, which quite unnoticed, and as if with the +best conscience, threatens nowadays to establish itself in the relations +of science and philosophy. I mean to say that one must have the right +out of one's own EXPERIENCE--experience, as it seems to me, always +implies unfortunate experience?--to treat of such an important question +of rank, so as not to speak of colour like the blind, or AGAINST science +like women and artists ("Ah! this dreadful science!" sigh their instinct +and their shame, "it always FINDS THINGS OUT!"). The declaration of +independence of the scientific man, his emancipation from philosophy, +is one of the subtler after-effects of democratic organization and +disorganization: the self-glorification and self-conceitedness of +the learned man is now everywhere in full bloom, and in its best +springtime--which does not mean to imply that in this case self-praise +smells sweet. Here also the instinct of the populace cries, "Freedom +from all masters!" and after science has, with the happiest results, +resisted theology, whose "hand-maid" it had been too long, it now +proposes in its wantonness and indiscretion to lay down laws for +philosophy, and in its turn to play the "master"--what am I saying! +to play the PHILOSOPHER on its own account. My memory--the memory of +a scientific man, if you please!--teems with the naivetes of insolence +which I have heard about philosophy and philosophers from young +naturalists and old physicians (not to mention the most cultured and +most conceited of all learned men, the philologists and schoolmasters, +who are both the one and the other by profession). On one occasion it +was the specialist and the Jack Horner who instinctively stood on the +defensive against all synthetic tasks and capabilities; at another time +it was the industrious worker who had got a scent of OTIUM and refined +luxuriousness in the internal economy of the philosopher, and felt +himself aggrieved and belittled thereby. On another occasion it was the +colour-blindness of the utilitarian, who sees nothing in philosophy but +a series of REFUTED systems, and an extravagant expenditure which "does +nobody any good". At another time the fear of disguised mysticism and of +the boundary-adjustment of knowledge became conspicuous, at another +time the disregard of individual philosophers, which had involuntarily +extended to disregard of philosophy generally. In fine, I found most +frequently, behind the proud disdain of philosophy in young scholars, +the evil after-effect of some particular philosopher, to whom on the +whole obedience had been foresworn, without, however, the spell of his +scornful estimates of other philosophers having been got rid of--the +result being a general ill-will to all philosophy. (Such seems to +me, for instance, the after-effect of Schopenhauer on the most modern +Germany: by his unintelligent rage against Hegel, he has succeeded in +severing the whole of the last generation of Germans from its connection +with German culture, which culture, all things considered, has been +an elevation and a divining refinement of the HISTORICAL SENSE, but +precisely at this point Schopenhauer himself was poor, irreceptive, +and un-German to the extent of ingeniousness.) On the whole, speaking +generally, it may just have been the humanness, all-too-humanness of the +modern philosophers themselves, in short, their contemptibleness, which +has injured most radically the reverence for philosophy and opened the +doors to the instinct of the populace. Let it but be acknowledged to +what an extent our modern world diverges from the whole style of the +world of Heraclitus, Plato, Empedocles, and whatever else all the royal +and magnificent anchorites of the spirit were called, and with what +justice an honest man of science MAY feel himself of a better family and +origin, in view of such representatives of philosophy, who, owing to +the fashion of the present day, are just as much aloft as they are down +below--in Germany, for instance, the two lions of Berlin, the anarchist +Eugen Duhring and the amalgamist Eduard von Hartmann. It is especially +the sight of those hotch-potch philosophers, who call themselves +"realists," or "positivists," which is calculated to implant a +dangerous distrust in the soul of a young and ambitious scholar those +philosophers, at the best, are themselves but scholars and specialists, +that is very evident! All of them are persons who have been vanquished +and BROUGHT BACK AGAIN under the dominion of science, who at one time +or another claimed more from themselves, without having a right to the +"more" and its responsibility--and who now, creditably, rancorously, and +vindictively, represent in word and deed, DISBELIEF in the master-task +and supremacy of philosophy After all, how could it be otherwise? +Science flourishes nowadays and has the good conscience clearly visible +on its countenance, while that to which the entire modern philosophy has +gradually sunk, the remnant of philosophy of the present day, excites +distrust and displeasure, if not scorn and pity Philosophy reduced to +a "theory of knowledge," no more in fact than a diffident science of +epochs and doctrine of forbearance a philosophy that never even +gets beyond the threshold, and rigorously DENIES itself the right +to enter--that is philosophy in its last throes, an end, an agony, +something that awakens pity. How could such a philosophy--RULE! + +205. The dangers that beset the evolution of the philosopher are, in +fact, so manifold nowadays, that one might doubt whether this fruit +could still come to maturity. The extent and towering structure of the +sciences have increased enormously, and therewith also the probability +that the philosopher will grow tired even as a learner, or will attach +himself somewhere and "specialize" so that he will no longer attain to +his elevation, that is to say, to his superspection, his circumspection, +and his DESPECTION. Or he gets aloft too late, when the best of his +maturity and strength is past, or when he is impaired, coarsened, and +deteriorated, so that his view, his general estimate of things, is no +longer of much importance. It is perhaps just the refinement of his +intellectual conscience that makes him hesitate and linger on the +way, he dreads the temptation to become a dilettante, a millepede, a +milleantenna, he knows too well that as a discerner, one who has lost +his self-respect no longer commands, no longer LEADS, unless he should +aspire to become a great play-actor, a philosophical Cagliostro and +spiritual rat-catcher--in short, a misleader. This is in the last +instance a question of taste, if it has not really been a question of +conscience. To double once more the philosopher's difficulties, there is +also the fact that he demands from himself a verdict, a Yea or Nay, not +concerning science, but concerning life and the worth of life--he learns +unwillingly to believe that it is his right and even his duty to obtain +this verdict, and he has to seek his way to the right and the belief +only through the most extensive (perhaps disturbing and destroying) +experiences, often hesitating, doubting, and dumbfounded. In fact, the +philosopher has long been mistaken and confused by the multitude, either +with the scientific man and ideal scholar, or with the religiously +elevated, desensualized, desecularized visionary and God-intoxicated +man; and even yet when one hears anybody praised, because he lives +"wisely," or "as a philosopher," it hardly means anything more than +"prudently and apart." Wisdom: that seems to the populace to be a kind +of flight, a means and artifice for withdrawing successfully from a +bad game; but the GENUINE philosopher--does it not seem so to US, +my friends?--lives "unphilosophically" and "unwisely," above all, +IMPRUDENTLY, and feels the obligation and burden of a hundred attempts +and temptations of life--he risks HIMSELF constantly, he plays THIS bad +game. + +206. In relation to the genius, that is to say, a being who either +ENGENDERS or PRODUCES--both words understood in their fullest sense--the +man of learning, the scientific average man, has always something of +the old maid about him; for, like her, he is not conversant with the two +principal functions of man. To both, of course, to the scholar and +to the old maid, one concedes respectability, as if by way of +indemnification--in these cases one emphasizes the respectability--and +yet, in the compulsion of this concession, one has the same admixture +of vexation. Let us examine more closely: what is the scientific man? +Firstly, a commonplace type of man, with commonplace virtues: that is +to say, a non-ruling, non-authoritative, and non-self-sufficient type +of man; he possesses industry, patient adaptableness to rank and file, +equability and moderation in capacity and requirement; he has the +instinct for people like himself, and for that which they require--for +instance: the portion of independence and green meadow without which +there is no rest from labour, the claim to honour and consideration +(which first and foremost presupposes recognition and recognisability), +the sunshine of a good name, the perpetual ratification of his value and +usefulness, with which the inward DISTRUST which lies at the bottom of +the heart of all dependent men and gregarious animals, has again and +again to be overcome. The learned man, as is appropriate, has also +maladies and faults of an ignoble kind: he is full of petty envy, and +has a lynx-eye for the weak points in those natures to whose elevations +he cannot attain. He is confiding, yet only as one who lets himself go, +but does not FLOW; and precisely before the man of the great current he +stands all the colder and more reserved--his eye is then like a smooth +and irresponsive lake, which is no longer moved by rapture or sympathy. +The worst and most dangerous thing of which a scholar is capable results +from the instinct of mediocrity of his type, from the Jesuitism of +mediocrity, which labours instinctively for the destruction of +the exceptional man, and endeavours to break--or still better, to +relax--every bent bow To relax, of course, with consideration, and +naturally with an indulgent hand--to RELAX with confiding sympathy +that is the real art of Jesuitism, which has always understood how to +introduce itself as the religion of sympathy. + +207. However gratefully one may welcome the OBJECTIVE spirit--and +who has not been sick to death of all subjectivity and its confounded +IPSISIMOSITY!--in the end, however, one must learn caution even with +regard to one's gratitude, and put a stop to the exaggeration with +which the unselfing and depersonalizing of the spirit has recently been +celebrated, as if it were the goal in itself, as if it were salvation +and glorification--as is especially accustomed to happen in the +pessimist school, which has also in its turn good reasons for paying the +highest honours to "disinterested knowledge" The objective man, who no +longer curses and scolds like the pessimist, the IDEAL man of learning +in whom the scientific instinct blossoms forth fully after a thousand +complete and partial failures, is assuredly one of the most costly +instruments that exist, but his place is in the hand of one who is more +powerful He is only an instrument, we may say, he is a MIRROR--he is no +"purpose in himself" The objective man is in truth a mirror accustomed +to prostration before everything that wants to be known, with such +desires only as knowing or "reflecting" implies--he waits until +something comes, and then expands himself sensitively, so that even the +light footsteps and gliding-past of spiritual beings may not be lost on +his surface and film Whatever "personality" he still possesses seems to +him accidental, arbitrary, or still oftener, disturbing, so much has he +come to regard himself as the passage and reflection of outside forms +and events He calls up the recollection of "himself" with an effort, +and not infrequently wrongly, he readily confounds himself with other +persons, he makes mistakes with regard to his own needs, and here only +is he unrefined and negligent Perhaps he is troubled about the health, +or the pettiness and confined atmosphere of wife and friend, or the lack +of companions and society--indeed, he sets himself to reflect on his +suffering, but in vain! His thoughts already rove away to the MORE +GENERAL case, and tomorrow he knows as little as he knew yesterday how +to help himself He does not now take himself seriously and devote time +to himself he is serene, NOT from lack of trouble, but from lack +of capacity for grasping and dealing with HIS trouble The habitual +complaisance with respect to all objects and experiences, the radiant +and impartial hospitality with which he receives everything that +comes his way, his habit of inconsiderate good-nature, of dangerous +indifference as to Yea and Nay: alas! there are enough of cases in which +he has to atone for these virtues of his!--and as man generally, he +becomes far too easily the CAPUT MORTUUM of such virtues. Should one +wish love or hatred from him--I mean love and hatred as God, woman, and +animal understand them--he will do what he can, and furnish what he can. +But one must not be surprised if it should not be much--if he should +show himself just at this point to be false, fragile, questionable, and +deteriorated. His love is constrained, his hatred is artificial, and +rather UN TOUR DE FORCE, a slight ostentation and exaggeration. He is +only genuine so far as he can be objective; only in his serene totality +is he still "nature" and "natural." His mirroring and eternally +self-polishing soul no longer knows how to affirm, no longer how to +deny; he does not command; neither does he destroy. "JE NE MEPRISE +PRESQUE RIEN"--he says, with Leibniz: let us not overlook nor undervalue +the PRESQUE! Neither is he a model man; he does not go in advance of any +one, nor after, either; he places himself generally too far off to have +any reason for espousing the cause of either good or evil. If he has +been so long confounded with the PHILOSOPHER, with the Caesarian trainer +and dictator of civilization, he has had far too much honour, and what +is more essential in him has been overlooked--he is an instrument, +something of a slave, though certainly the sublimest sort of slave, but +nothing in himself--PRESQUE RIEN! The objective man is an instrument, +a costly, easily injured, easily tarnished measuring instrument and +mirroring apparatus, which is to be taken care of and respected; but he +is no goal, not outgoing nor upgoing, no complementary man in whom the +REST of existence justifies itself, no termination--and still less a +commencement, an engendering, or primary cause, nothing hardy, powerful, +self-centred, that wants to be master; but rather only a soft, inflated, +delicate, movable potter's-form, that must wait for some kind of content +and frame to "shape" itself thereto--for the most part a man without +frame and content, a "selfless" man. Consequently, also, nothing for +women, IN PARENTHESI. + +208. When a philosopher nowadays makes known that he is not a skeptic--I +hope that has been gathered from the foregoing description of the +objective spirit?--people all hear it impatiently; they regard him on +that account with some apprehension, they would like to ask so many, +many questions... indeed among timid hearers, of whom there are now so +many, he is henceforth said to be dangerous. With his repudiation of +skepticism, it seems to them as if they heard some evil-threatening +sound in the distance, as if a new kind of explosive were being tried +somewhere, a dynamite of the spirit, perhaps a newly discovered Russian +NIHILINE, a pessimism BONAE VOLUNTATIS, that not only denies, means +denial, but--dreadful thought! PRACTISES denial. Against this kind of +"good-will"--a will to the veritable, actual negation of life--there is, +as is generally acknowledged nowadays, no better soporific and sedative +than skepticism, the mild, pleasing, lulling poppy of skepticism; +and Hamlet himself is now prescribed by the doctors of the day as an +antidote to the "spirit," and its underground noises. "Are not our ears +already full of bad sounds?" say the skeptics, as lovers of repose, and +almost as a kind of safety police; "this subterranean Nay is terrible! +Be still, ye pessimistic moles!" The skeptic, in effect, that delicate +creature, is far too easily frightened; his conscience is schooled so +as to start at every Nay, and even at that sharp, decided Yea, and feels +something like a bite thereby. Yea! and Nay!--they seem to him opposed +to morality; he loves, on the contrary, to make a festival to his virtue +by a noble aloofness, while perhaps he says with Montaigne: "What do I +know?" Or with Socrates: "I know that I know nothing." Or: "Here I do +not trust myself, no door is open to me." Or: "Even if the door were +open, why should I enter immediately?" Or: "What is the use of any hasty +hypotheses? It might quite well be in good taste to make no hypotheses +at all. Are you absolutely obliged to straighten at once what is +crooked? to stuff every hole with some kind of oakum? Is there not time +enough for that? Has not the time leisure? Oh, ye demons, can ye not +at all WAIT? The uncertain also has its charms, the Sphinx, too, is a +Circe, and Circe, too, was a philosopher."--Thus does a skeptic console +himself; and in truth he needs some consolation. For skepticism is +the most spiritual expression of a certain many-sided physiological +temperament, which in ordinary language is called nervous debility and +sickliness; it arises whenever races or classes which have been long +separated, decisively and suddenly blend with one another. In the new +generation, which has inherited as it were different standards and +valuations in its blood, everything is disquiet, derangement, doubt, and +tentativeness; the best powers operate restrictively, the very virtues +prevent each other growing and becoming strong, equilibrium, ballast, +and perpendicular stability are lacking in body and soul. That, however, +which is most diseased and degenerated in such nondescripts is the +WILL; they are no longer familiar with independence of decision, or +the courageous feeling of pleasure in willing--they are doubtful of the +"freedom of the will" even in their dreams Our present-day Europe, +the scene of a senseless, precipitate attempt at a radical blending of +classes, and CONSEQUENTLY of races, is therefore skeptical in all its +heights and depths, sometimes exhibiting the mobile skepticism which +springs impatiently and wantonly from branch to branch, sometimes with +gloomy aspect, like a cloud over-charged with interrogative signs--and +often sick unto death of its will! Paralysis of will, where do we not +find this cripple sitting nowadays! And yet how bedecked oftentimes' How +seductively ornamented! There are the finest gala dresses and disguises +for this disease, and that, for instance, most of what places itself +nowadays in the show-cases as "objectiveness," "the scientific spirit," +"L'ART POUR L'ART," and "pure voluntary knowledge," is only decked-out +skepticism and paralysis of will--I am ready to answer for this +diagnosis of the European disease--The disease of the will is diffused +unequally over Europe, it is worst and most varied where civilization +has longest prevailed, it decreases according as "the barbarian" +still--or again--asserts his claims under the loose drapery of Western +culture It is therefore in the France of today, as can be readily +disclosed and comprehended, that the will is most infirm, and France, +which has always had a masterly aptitude for converting even the +portentous crises of its spirit into something charming and seductive, +now manifests emphatically its intellectual ascendancy over Europe, +by being the school and exhibition of all the charms of skepticism The +power to will and to persist, moreover, in a resolution, is already +somewhat stronger in Germany, and again in the North of Germany it +is stronger than in Central Germany, it is considerably stronger in +England, Spain, and Corsica, associated with phlegm in the former and +with hard skulls in the latter--not to mention Italy, which is too young +yet to know what it wants, and must first show whether it can exercise +will, but it is strongest and most surprising of all in that immense +middle empire where Europe as it were flows back to Asia--namely, in +Russia There the power to will has been long stored up and accumulated, +there the will--uncertain whether to be negative or affirmative--waits +threateningly to be discharged (to borrow their pet phrase from our +physicists) Perhaps not only Indian wars and complications in Asia would +be necessary to free Europe from its greatest danger, but also internal +subversion, the shattering of the empire into small states, and above +all the introduction of parliamentary imbecility, together with the +obligation of every one to read his newspaper at breakfast I do not +say this as one who desires it, in my heart I should rather prefer the +contrary--I mean such an increase in the threatening attitude of +Russia, that Europe would have to make up its mind to become equally +threatening--namely, TO ACQUIRE ONE WILL, by means of a new caste to +rule over the Continent, a persistent, dreadful will of its own, that +can set its aims thousands of years ahead; so that the long spun-out +comedy of its petty-statism, and its dynastic as well as its democratic +many-willed-ness, might finally be brought to a close. The time for +petty politics is past; the next century will bring the struggle for the +dominion of the world--the COMPULSION to great politics. + +209. As to how far the new warlike age on which we Europeans have +evidently entered may perhaps favour the growth of another and stronger +kind of skepticism, I should like to express myself preliminarily +merely by a parable, which the lovers of German history will already +understand. That unscrupulous enthusiast for big, handsome grenadiers +(who, as King of Prussia, brought into being a military and skeptical +genius--and therewith, in reality, the new and now triumphantly emerged +type of German), the problematic, crazy father of Frederick the Great, +had on one point the very knack and lucky grasp of the genius: he knew +what was then lacking in Germany, the want of which was a hundred times +more alarming and serious than any lack of culture and social form--his +ill-will to the young Frederick resulted from the anxiety of a profound +instinct. MEN WERE LACKING; and he suspected, to his bitterest regret, +that his own son was not man enough. There, however, he deceived +himself; but who would not have deceived himself in his place? He saw +his son lapsed to atheism, to the ESPRIT, to the pleasant frivolity of +clever Frenchmen--he saw in the background the great bloodsucker, the +spider skepticism; he suspected the incurable wretchedness of a heart no +longer hard enough either for evil or good, and of a broken will that no +longer commands, is no longer ABLE to command. Meanwhile, however, +there grew up in his son that new kind of harder and more dangerous +skepticism--who knows TO WHAT EXTENT it was encouraged just by +his father's hatred and the icy melancholy of a will condemned to +solitude?--the skepticism of daring manliness, which is closely related +to the genius for war and conquest, and made its first entrance into +Germany in the person of the great Frederick. This skepticism despises +and nevertheless grasps; it undermines and takes possession; it does +not believe, but it does not thereby lose itself; it gives the spirit a +dangerous liberty, but it keeps strict guard over the heart. It is the +GERMAN form of skepticism, which, as a continued Fredericianism, risen +to the highest spirituality, has kept Europe for a considerable time +under the dominion of the German spirit and its critical and historical +distrust Owing to the insuperably strong and tough masculine character +of the great German philologists and historical critics (who, +rightly estimated, were also all of them artists of destruction +and dissolution), a NEW conception of the German spirit gradually +established itself--in spite of all Romanticism in music and +philosophy--in which the leaning towards masculine skepticism was +decidedly prominent whether, for instance, as fearlessness of gaze, as +courage and sternness of the dissecting hand, or as resolute will to +dangerous voyages of discovery, to spiritualized North Pole expeditions +under barren and dangerous skies. There may be good grounds for it when +warm-blooded and superficial humanitarians cross themselves before this +spirit, CET ESPRIT FATALISTE, IRONIQUE, MEPHISTOPHELIQUE, as Michelet +calls it, not without a shudder. But if one would realize how +characteristic is this fear of the "man" in the German spirit which +awakened Europe out of its "dogmatic slumber," let us call to mind the +former conception which had to be overcome by this new one--and that +it is not so very long ago that a masculinized woman could dare, with +unbridled presumption, to recommend the Germans to the interest of +Europe as gentle, good-hearted, weak-willed, and poetical fools. +Finally, let us only understand profoundly enough Napoleon's +astonishment when he saw Goethe it reveals what had been regarded for +centuries as the "German spirit" "VOILA UN HOMME!"--that was as much as +to say "But this is a MAN! And I only expected to see a German!" + +210. Supposing, then, that in the picture of the philosophers of the +future, some trait suggests the question whether they must not perhaps +be skeptics in the last-mentioned sense, something in them would only be +designated thereby--and not they themselves. With equal right they might +call themselves critics, and assuredly they will be men of experiments. +By the name with which I ventured to baptize them, I have already +expressly emphasized their attempting and their love of attempting is +this because, as critics in body and soul, they will love to make use +of experiments in a new, and perhaps wider and more dangerous sense? In +their passion for knowledge, will they have to go further in daring and +painful attempts than the sensitive and pampered taste of a democratic +century can approve of?--There is no doubt these coming ones will be +least able to dispense with the serious and not unscrupulous qualities +which distinguish the critic from the skeptic I mean the certainty as to +standards of worth, the conscious employment of a unity of method, +the wary courage, the standing-alone, and the capacity for +self-responsibility, indeed, they will avow among themselves a DELIGHT +in denial and dissection, and a certain considerate cruelty, which knows +how to handle the knife surely and deftly, even when the heart bleeds +They will be STERNER (and perhaps not always towards themselves only) +than humane people may desire, they will not deal with the "truth" in +order that it may "please" them, or "elevate" and "inspire" them--they +will rather have little faith in "TRUTH" bringing with it such revels +for the feelings. They will smile, those rigorous spirits, when any one +says in their presence "That thought elevates me, why should it not be +true?" or "That work enchants me, why should it not be beautiful?" or +"That artist enlarges me, why should he not be great?" Perhaps they +will not only have a smile, but a genuine disgust for all that is thus +rapturous, idealistic, feminine, and hermaphroditic, and if any one +could look into their inmost hearts, he would not easily find therein +the intention to reconcile "Christian sentiments" with "antique taste," +or even with "modern parliamentarism" (the kind of reconciliation +necessarily found even among philosophers in our very uncertain and +consequently very conciliatory century). Critical discipline, and every +habit that conduces to purity and rigour in intellectual matters, +will not only be demanded from themselves by these philosophers of +the future, they may even make a display thereof as their special +adornment--nevertheless they will not want to be called critics on that +account. It will seem to them no small indignity to philosophy to +have it decreed, as is so welcome nowadays, that "philosophy itself is +criticism and critical science--and nothing else whatever!" Though this +estimate of philosophy may enjoy the approval of all the Positivists of +France and Germany (and possibly it even flattered the heart and taste +of KANT: let us call to mind the titles of his principal works), our new +philosophers will say, notwithstanding, that critics are instruments of +the philosopher, and just on that account, as instruments, they are +far from being philosophers themselves! Even the great Chinaman of +Konigsberg was only a great critic. + +211. I insist upon it that people finally cease confounding +philosophical workers, and in general scientific men, with +philosophers--that precisely here one should strictly give "each his +own," and not give those far too much, these far too little. It may +be necessary for the education of the real philosopher that he himself +should have once stood upon all those steps upon which his servants, +the scientific workers of philosophy, remain standing, and MUST remain +standing he himself must perhaps have been critic, and dogmatist, +and historian, and besides, poet, and collector, and traveler, and +riddle-reader, and moralist, and seer, and "free spirit," and almost +everything, in order to traverse the whole range of human values +and estimations, and that he may BE ABLE with a variety of eyes and +consciences to look from a height to any distance, from a depth up +to any height, from a nook into any expanse. But all these are only +preliminary conditions for his task; this task itself demands something +else--it requires him TO CREATE VALUES. The philosophical workers, after +the excellent pattern of Kant and Hegel, have to fix and formalize some +great existing body of valuations--that is to say, former DETERMINATIONS +OF VALUE, creations of value, which have become prevalent, and are for +a time called "truths"--whether in the domain of the LOGICAL, the +POLITICAL (moral), or the ARTISTIC. It is for these investigators to +make whatever has happened and been esteemed hitherto, conspicuous, +conceivable, intelligible, and manageable, to shorten everything long, +even "time" itself, and to SUBJUGATE the entire past: an immense and +wonderful task, in the carrying out of which all refined pride, all +tenacious will, can surely find satisfaction. THE REAL PHILOSOPHERS, +HOWEVER, ARE COMMANDERS AND LAW-GIVERS; they say: "Thus SHALL it be!" +They determine first the Whither and the Why of mankind, and thereby +set aside the previous labour of all philosophical workers, and all +subjugators of the past--they grasp at the future with a creative +hand, and whatever is and was, becomes for them thereby a means, an +instrument, and a hammer. Their "knowing" is CREATING, their creating +is a law-giving, their will to truth is--WILL TO POWER.--Are there at +present such philosophers? Have there ever been such philosophers? MUST +there not be such philosophers some day? ... + +212. It is always more obvious to me that the philosopher, as a man +INDISPENSABLE for the morrow and the day after the morrow, has ever +found himself, and HAS BEEN OBLIGED to find himself, in contradiction +to the day in which he lives; his enemy has always been the ideal of his +day. Hitherto all those extraordinary furtherers of humanity whom one +calls philosophers--who rarely regarded themselves as lovers of wisdom, +but rather as disagreeable fools and dangerous interrogators--have found +their mission, their hard, involuntary, imperative mission (in the end, +however, the greatness of their mission), in being the bad conscience of +their age. In putting the vivisector's knife to the breast of the very +VIRTUES OF THEIR AGE, they have betrayed their own secret; it has been +for the sake of a NEW greatness of man, a new untrodden path to +his aggrandizement. They have always disclosed how much hypocrisy, +indolence, self-indulgence, and self-neglect, how much falsehood was +concealed under the most venerated types of contemporary morality, how +much virtue was OUTLIVED, they have always said "We must remove hence to +where YOU are least at home" In the face of a world of "modern ideas," +which would like to confine every one in a corner, in a "specialty," a +philosopher, if there could be philosophers nowadays, would be compelled +to place the greatness of man, the conception of "greatness," precisely +in his comprehensiveness and multifariousness, in his all-roundness, he +would even determine worth and rank according to the amount and variety +of that which a man could bear and take upon himself, according to the +EXTENT to which a man could stretch his responsibility Nowadays the +taste and virtue of the age weaken and attenuate the will, nothing is +so adapted to the spirit of the age as weakness of will consequently, in +the ideal of the philosopher, strength of will, sternness, and capacity +for prolonged resolution, must specially be included in the conception +of "greatness", with as good a right as the opposite doctrine, with its +ideal of a silly, renouncing, humble, selfless humanity, was suited to +an opposite age--such as the sixteenth century, which suffered from its +accumulated energy of will, and from the wildest torrents and floods +of selfishness In the time of Socrates, among men only of worn-out +instincts, old conservative Athenians who let themselves go--"for the +sake of happiness," as they said, for the sake of pleasure, as their +conduct indicated--and who had continually on their lips the old pompous +words to which they had long forfeited the right by the life they led, +IRONY was perhaps necessary for greatness of soul, the wicked Socratic +assurance of the old physician and plebeian, who cut ruthlessly into his +own flesh, as into the flesh and heart of the "noble," with a look that +said plainly enough "Do not dissemble before me! here--we are equal!" +At present, on the contrary, when throughout Europe the herding-animal +alone attains to honours, and dispenses honours, when "equality of +right" can too readily be transformed into equality in wrong--I mean to +say into general war against everything rare, strange, and privileged, +against the higher man, the higher soul, the higher duty, the higher +responsibility, the creative plenipotence and lordliness--at present +it belongs to the conception of "greatness" to be noble, to wish to be +apart, to be capable of being different, to stand alone, to have to live +by personal initiative, and the philosopher will betray something of his +own ideal when he asserts "He shall be the greatest who can be the most +solitary, the most concealed, the most divergent, the man beyond good +and evil, the master of his virtues, and of super-abundance of will; +precisely this shall be called GREATNESS: as diversified as can be +entire, as ample as can be full." And to ask once more the question: Is +greatness POSSIBLE--nowadays? + +213. It is difficult to learn what a philosopher is, because it cannot +be taught: one must "know" it by experience--or one should have the +pride NOT to know it. The fact that at present people all talk of things +of which they CANNOT have any experience, is true more especially +and unfortunately as concerns the philosopher and philosophical +matters:--the very few know them, are permitted to know them, and +all popular ideas about them are false. Thus, for instance, the truly +philosophical combination of a bold, exuberant spirituality which runs +at presto pace, and a dialectic rigour and necessity which makes no +false step, is unknown to most thinkers and scholars from their own +experience, and therefore, should any one speak of it in their +presence, it is incredible to them. They conceive of every necessity as +troublesome, as a painful compulsory obedience and state of constraint; +thinking itself is regarded by them as something slow and hesitating, +almost as a trouble, and often enough as "worthy of the SWEAT of the +noble"--but not at all as something easy and divine, closely related +to dancing and exuberance! "To think" and to take a matter "seriously," +"arduously"--that is one and the same thing to them; such only has been +their "experience."--Artists have here perhaps a finer intuition; they +who know only too well that precisely when they no longer do anything +"arbitrarily," and everything of necessity, their feeling of freedom, +of subtlety, of power, of creatively fixing, disposing, and shaping, +reaches its climax--in short, that necessity and "freedom of will" are +then the same thing with them. There is, in fine, a gradation of rank +in psychical states, to which the gradation of rank in the problems +corresponds; and the highest problems repel ruthlessly every one who +ventures too near them, without being predestined for their solution +by the loftiness and power of his spirituality. Of what use is it for +nimble, everyday intellects, or clumsy, honest mechanics and empiricists +to press, in their plebeian ambition, close to such problems, and as +it were into this "holy of holies"--as so often happens nowadays! But +coarse feet must never tread upon such carpets: this is provided for in +the primary law of things; the doors remain closed to those intruders, +though they may dash and break their heads thereon. People have always +to be born to a high station, or, more definitely, they have to be BRED +for it: a person has only a right to philosophy--taking the word in +its higher significance--in virtue of his descent; the ancestors, the +"blood," decide here also. Many generations must have prepared the way +for the coming of the philosopher; each of his virtues must have been +separately acquired, nurtured, transmitted, and embodied; not only the +bold, easy, delicate course and current of his thoughts, but above all +the readiness for great responsibilities, the majesty of ruling glance +and contemning look, the feeling of separation from the multitude with +their duties and virtues, the kindly patronage and defense of whatever +is misunderstood and calumniated, be it God or devil, the delight and +practice of supreme justice, the art of commanding, the amplitude of +will, the lingering eye which rarely admires, rarely looks up, rarely +loves.... + + + +CHAPTER VII. OUR VIRTUES + + +214. OUR Virtues?--It is probable that we, too, have still our virtues, +although naturally they are not those sincere and massive virtues on +account of which we hold our grandfathers in esteem and also at a little +distance from us. We Europeans of the day after tomorrow, we firstlings +of the twentieth century--with all our dangerous curiosity, our +multifariousness and art of disguising, our mellow and seemingly +sweetened cruelty in sense and spirit--we shall presumably, IF we must +have virtues, have those only which have come to agreement with our most +secret and heartfelt inclinations, with our most ardent requirements: +well, then, let us look for them in our labyrinths!--where, as we know, +so many things lose themselves, so many things get quite lost! And is +there anything finer than to SEARCH for one's own virtues? Is it not +almost to BELIEVE in one's own virtues? But this "believing in one's +own virtues"--is it not practically the same as what was formerly called +one's "good conscience," that long, respectable pigtail of an idea, +which our grandfathers used to hang behind their heads, and often enough +also behind their understandings? It seems, therefore, that however +little we may imagine ourselves to be old-fashioned and grandfatherly +respectable in other respects, in one thing we are nevertheless the +worthy grandchildren of our grandfathers, we last Europeans with good +consciences: we also still wear their pigtail.--Ah! if you only knew how +soon, so very soon--it will be different! + +215. As in the stellar firmament there are sometimes two suns which +determine the path of one planet, and in certain cases suns of different +colours shine around a single planet, now with red light, now with +green, and then simultaneously illumine and flood it with motley +colours: so we modern men, owing to the complicated mechanism of our +"firmament," are determined by DIFFERENT moralities; our actions shine +alternately in different colours, and are seldom unequivocal--and there +are often cases, also, in which our actions are MOTLEY-COLOURED. + +216. To love one's enemies? I think that has been well learnt: it takes +place thousands of times at present on a large and small scale; indeed, +at times the higher and sublimer thing takes place:--we learn to DESPISE +when we love, and precisely when we love best; all of it, however, +unconsciously, without noise, without ostentation, with the shame and +secrecy of goodness, which forbids the utterance of the pompous word +and the formula of virtue. Morality as attitude--is opposed to our taste +nowadays. This is ALSO an advance, as it was an advance in our fathers +that religion as an attitude finally became opposed to their taste, +including the enmity and Voltairean bitterness against religion (and all +that formerly belonged to freethinker-pantomime). It is the music in our +conscience, the dance in our spirit, to which Puritan litanies, moral +sermons, and goody-goodness won't chime. + +217. Let us be careful in dealing with those who attach great importance +to being credited with moral tact and subtlety in moral discernment! +They never forgive us if they have once made a mistake BEFORE us +(or even with REGARD to us)--they inevitably become our instinctive +calumniators and detractors, even when they still remain our +"friends."--Blessed are the forgetful: for they "get the better" even of +their blunders. + +218. The psychologists of France--and where else are there still +psychologists nowadays?--have never yet exhausted their bitter and +manifold enjoyment of the betise bourgeoise, just as though... in +short, they betray something thereby. Flaubert, for instance, the honest +citizen of Rouen, neither saw, heard, nor tasted anything else in the +end; it was his mode of self-torment and refined cruelty. As this is +growing wearisome, I would now recommend for a change something else +for a pleasure--namely, the unconscious astuteness with which good, fat, +honest mediocrity always behaves towards loftier spirits and the tasks +they have to perform, the subtle, barbed, Jesuitical astuteness, which +is a thousand times subtler than the taste and understanding of the +middle-class in its best moments--subtler even than the understanding of +its victims:--a repeated proof that "instinct" is the most intelligent +of all kinds of intelligence which have hitherto been discovered. In +short, you psychologists, study the philosophy of the "rule" in its +struggle with the "exception": there you have a spectacle fit for Gods +and godlike malignity! Or, in plainer words, practise vivisection on +"good people," on the "homo bonae voluntatis," ON YOURSELVES! + +219. The practice of judging and condemning morally, is the favourite +revenge of the intellectually shallow on those who are less so, it is +also a kind of indemnity for their being badly endowed by nature, +and finally, it is an opportunity for acquiring spirit and BECOMING +subtle--malice spiritualises. They are glad in their inmost heart that +there is a standard according to which those who are over-endowed with +intellectual goods and privileges, are equal to them, they contend for +the "equality of all before God," and almost NEED the belief in God for +this purpose. It is among them that the most powerful antagonists of +atheism are found. If any one were to say to them "A lofty spirituality +is beyond all comparison with the honesty and respectability of a merely +moral man"--it would make them furious, I shall take care not to say +so. I would rather flatter them with my theory that lofty spirituality +itself exists only as the ultimate product of moral qualities, that it +is a synthesis of all qualities attributed to the "merely moral" man, +after they have been acquired singly through long training and practice, +perhaps during a whole series of generations, that lofty spirituality +is precisely the spiritualising of justice, and the beneficent severity +which knows that it is authorized to maintain GRADATIONS OF RANK in the +world, even among things--and not only among men. + +220. Now that the praise of the "disinterested person" is so popular +one must--probably not without some danger--get an idea of WHAT people +actually take an interest in, and what are the things generally which +fundamentally and profoundly concern ordinary men--including the +cultured, even the learned, and perhaps philosophers also, if +appearances do not deceive. The fact thereby becomes obvious that the +greater part of what interests and charms higher natures, and more +refined and fastidious tastes, seems absolutely "uninteresting" to +the average man--if, notwithstanding, he perceive devotion to these +interests, he calls it desinteresse, and wonders how it is possible to +act "disinterestedly." There have been philosophers who could give this +popular astonishment a seductive and mystical, other-worldly expression +(perhaps because they did not know the higher nature by experience?), +instead of stating the naked and candidly reasonable truth that +"disinterested" action is very interesting and "interested" action, +provided that... "And love?"--What! Even an action for love's sake +shall be "unegoistic"? But you fools--! "And the praise of the +self-sacrificer?"--But whoever has really offered sacrifice knows that +he wanted and obtained something for it--perhaps something from himself +for something from himself; that he relinquished here in order to have +more there, perhaps in general to be more, or even feel himself "more." +But this is a realm of questions and answers in which a more fastidious +spirit does not like to stay: for here truth has to stifle her yawns so +much when she is obliged to answer. And after all, truth is a woman; one +must not use force with her. + +221. "It sometimes happens," said a moralistic pedant and +trifle-retailer, "that I honour and respect an unselfish man: not, +however, because he is unselfish, but because I think he has a right to +be useful to another man at his own expense. In short, the question +is always who HE is, and who THE OTHER is. For instance, in a person +created and destined for command, self-denial and modest retirement, +instead of being virtues, would be the waste of virtues: so it seems +to me. Every system of unegoistic morality which takes itself +unconditionally and appeals to every one, not only sins against good +taste, but is also an incentive to sins of omission, an ADDITIONAL +seduction under the mask of philanthropy--and precisely a seduction and +injury to the higher, rarer, and more privileged types of men. Moral +systems must be compelled first of all to bow before the GRADATIONS OF +RANK; their presumption must be driven home to their conscience--until +they thoroughly understand at last that it is IMMORAL to say that 'what +is right for one is proper for another.'"--So said my moralistic pedant +and bonhomme. Did he perhaps deserve to be laughed at when he thus +exhorted systems of morals to practise morality? But one should not be +too much in the right if one wishes to have the laughers on ONE'S OWN +side; a grain of wrong pertains even to good taste. + +222. Wherever sympathy (fellow-suffering) is preached nowadays--and, +if I gather rightly, no other religion is any longer preached--let the +psychologist have his ears open through all the vanity, through all the +noise which is natural to these preachers (as to all preachers), he will +hear a hoarse, groaning, genuine note of SELF-CONTEMPT. It belongs +to the overshadowing and uglifying of Europe, which has been on +the increase for a century (the first symptoms of which are already +specified documentarily in a thoughtful letter of Galiani to Madame +d'Epinay)--IF IT IS NOT REALLY THE CAUSE THEREOF! The man of +"modern ideas," the conceited ape, is excessively dissatisfied with +himself--this is perfectly certain. He suffers, and his vanity wants him +only "to suffer with his fellows." + +223. The hybrid European--a tolerably ugly plebeian, taken all in +all--absolutely requires a costume: he needs history as a storeroom +of costumes. To be sure, he notices that none of the costumes fit him +properly--he changes and changes. Let us look at the nineteenth century +with respect to these hasty preferences and changes in its masquerades +of style, and also with respect to its moments of desperation on account +of "nothing suiting" us. It is in vain to get ourselves up as romantic, +or classical, or Christian, or Florentine, or barocco, or "national," +in moribus et artibus: it does not "clothe us"! But the "spirit," +especially the "historical spirit," profits even by this desperation: +once and again a new sample of the past or of the foreign is tested, +put on, taken off, packed up, and above all studied--we are the first +studious age in puncto of "costumes," I mean as concerns morals, +articles of belief, artistic tastes, and religions; we are prepared as +no other age has ever been for a carnival in the grand style, for the +most spiritual festival--laughter and arrogance, for the transcendental +height of supreme folly and Aristophanic ridicule of the world. Perhaps +we are still discovering the domain of our invention just here, the +domain where even we can still be original, probably as parodists of +the world's history and as God's Merry-Andrews,--perhaps, though nothing +else of the present have a future, our laughter itself may have a +future! + +224. The historical sense (or the capacity for divining quickly +the order of rank of the valuations according to which a people, a +community, or an individual has lived, the "divining instinct" for the +relationships of these valuations, for the relation of the authority +of the valuations to the authority of the operating forces),--this +historical sense, which we Europeans claim as our specialty, has come +to us in the train of the enchanting and mad semi-barbarity into which +Europe has been plunged by the democratic mingling of classes and +races--it is only the nineteenth century that has recognized this +faculty as its sixth sense. Owing to this mingling, the past of every +form and mode of life, and of cultures which were formerly closely +contiguous and superimposed on one another, flows forth into us "modern +souls"; our instincts now run back in all directions, we ourselves are +a kind of chaos: in the end, as we have said, the spirit perceives its +advantage therein. By means of our semi-barbarity in body and in desire, +we have secret access everywhere, such as a noble age never had; we have +access above all to the labyrinth of imperfect civilizations, and to +every form of semi-barbarity that has at any time existed on earth; and +in so far as the most considerable part of human civilization hitherto +has just been semi-barbarity, the "historical sense" implies almost the +sense and instinct for everything, the taste and tongue for everything: +whereby it immediately proves itself to be an IGNOBLE sense. For +instance, we enjoy Homer once more: it is perhaps our happiest +acquisition that we know how to appreciate Homer, whom men of +distinguished culture (as the French of the seventeenth century, like +Saint-Evremond, who reproached him for his ESPRIT VASTE, and even +Voltaire, the last echo of the century) cannot and could not so easily +appropriate--whom they scarcely permitted themselves to enjoy. The very +decided Yea and Nay of their palate, their promptly ready disgust, their +hesitating reluctance with regard to everything strange, their horror of +the bad taste even of lively curiosity, and in general the averseness of +every distinguished and self-sufficing culture to avow a new desire, +a dissatisfaction with its own condition, or an admiration of what is +strange: all this determines and disposes them unfavourably even towards +the best things of the world which are not their property or could not +become their prey--and no faculty is more unintelligible to such men +than just this historical sense, with its truckling, plebeian +curiosity. The case is not different with Shakespeare, that marvelous +Spanish-Moorish-Saxon synthesis of taste, over whom an ancient Athenian +of the circle of AEschylus would have half-killed himself with laughter +or irritation: but we--accept precisely this wild motleyness, this +medley of the most delicate, the most coarse, and the most artificial, +with a secret confidence and cordiality; we enjoy it as a refinement +of art reserved expressly for us, and allow ourselves to be as little +disturbed by the repulsive fumes and the proximity of the English +populace in which Shakespeare's art and taste lives, as perhaps on +the Chiaja of Naples, where, with all our senses awake, we go our way, +enchanted and voluntarily, in spite of the drain-odour of the lower +quarters of the town. That as men of the "historical sense" we have +our virtues, is not to be disputed:--we are unpretentious, unselfish, +modest, brave, habituated to self-control and self-renunciation, very +grateful, very patient, very complaisant--but with all this we are +perhaps not very "tasteful." Let us finally confess it, that what is +most difficult for us men of the "historical sense" to grasp, feel, +taste, and love, what finds us fundamentally prejudiced and almost +hostile, is precisely the perfection and ultimate maturity in every +culture and art, the essentially noble in works and men, their moment +of smooth sea and halcyon self-sufficiency, the goldenness and coldness +which all things show that have perfected themselves. Perhaps our great +virtue of the historical sense is in necessary contrast to GOOD taste, +at least to the very bad taste; and we can only evoke in ourselves +imperfectly, hesitatingly, and with compulsion the small, short, and +happy godsends and glorifications of human life as they shine here and +there: those moments and marvelous experiences when a great power has +voluntarily come to a halt before the boundless and infinite,--when a +super-abundance of refined delight has been enjoyed by a sudden checking +and petrifying, by standing firmly and planting oneself fixedly on still +trembling ground. PROPORTIONATENESS is strange to us, let us confess it +to ourselves; our itching is really the itching for the infinite, the +immeasurable. Like the rider on his forward panting horse, we let the +reins fall before the infinite, we modern men, we semi-barbarians--and +are only in OUR highest bliss when we--ARE IN MOST DANGER. + +225. Whether it be hedonism, pessimism, utilitarianism, or eudaemonism, +all those modes of thinking which measure the worth of things according +to PLEASURE and PAIN, that is, according to accompanying circumstances +and secondary considerations, are plausible modes of thought and +naivetes, which every one conscious of CREATIVE powers and an artist's +conscience will look down upon with scorn, though not without sympathy. +Sympathy for you!--to be sure, that is not sympathy as you understand +it: it is not sympathy for social "distress," for "society" with its +sick and misfortuned, for the hereditarily vicious and defective who lie +on the ground around us; still less is it sympathy for the grumbling, +vexed, revolutionary slave-classes who strive after power--they call it +"freedom." OUR sympathy is a loftier and further-sighted sympathy:--we +see how MAN dwarfs himself, how YOU dwarf him! and there are moments +when we view YOUR sympathy with an indescribable anguish, when we resist +it,--when we regard your seriousness as more dangerous than any kind +of levity. You want, if possible--and there is not a more foolish "if +possible"--TO DO AWAY WITH SUFFERING; and we?--it really seems that WE +would rather have it increased and made worse than it has ever been! +Well-being, as you understand it--is certainly not a goal; it seems +to us an END; a condition which at once renders man ludicrous and +contemptible--and makes his destruction DESIRABLE! The discipline +of suffering, of GREAT suffering--know ye not that it is only THIS +discipline that has produced all the elevations of humanity hitherto? +The tension of soul in misfortune which communicates to it its energy, +its shuddering in view of rack and ruin, its inventiveness and bravery +in undergoing, enduring, interpreting, and exploiting misfortune, and +whatever depth, mystery, disguise, spirit, artifice, or greatness has +been bestowed upon the soul--has it not been bestowed through suffering, +through the discipline of great suffering? In man CREATURE and CREATOR +are united: in man there is not only matter, shred, excess, clay, mire, +folly, chaos; but there is also the creator, the sculptor, the hardness +of the hammer, the divinity of the spectator, and the seventh day--do +ye understand this contrast? And that YOUR sympathy for the "creature +in man" applies to that which has to be fashioned, bruised, forged, +stretched, roasted, annealed, refined--to that which must necessarily +SUFFER, and IS MEANT to suffer? And our sympathy--do ye not understand +what our REVERSE sympathy applies to, when it resists your sympathy as +the worst of all pampering and enervation?--So it is sympathy AGAINST +sympathy!--But to repeat it once more, there are higher problems than +the problems of pleasure and pain and sympathy; and all systems of +philosophy which deal only with these are naivetes. + +226. WE IMMORALISTS.--This world with which WE are concerned, in which +we have to fear and love, this almost invisible, inaudible world of +delicate command and delicate obedience, a world of "almost" in every +respect, captious, insidious, sharp, and tender--yes, it is well +protected from clumsy spectators and familiar curiosity! We are +woven into a strong net and garment of duties, and CANNOT disengage +ourselves--precisely here, we are "men of duty," even we! Occasionally, +it is true, we dance in our "chains" and betwixt our "swords"; it +is none the less true that more often we gnash our teeth under the +circumstances, and are impatient at the secret hardship of our lot. But +do what we will, fools and appearances say of us: "These are men WITHOUT +duty,"--we have always fools and appearances against us! + +227. Honesty, granting that it is the virtue of which we cannot rid +ourselves, we free spirits--well, we will labour at it with all our +perversity and love, and not tire of "perfecting" ourselves in OUR +virtue, which alone remains: may its glance some day overspread like +a gilded, blue, mocking twilight this aging civilization with its dull +gloomy seriousness! And if, nevertheless, our honesty should one day +grow weary, and sigh, and stretch its limbs, and find us too hard, and +would fain have it pleasanter, easier, and gentler, like an agreeable +vice, let us remain HARD, we latest Stoics, and let us send to its +help whatever devilry we have in us:--our disgust at the clumsy +and undefined, our "NITIMUR IN VETITUM," our love of adventure, +our sharpened and fastidious curiosity, our most subtle, disguised, +intellectual Will to Power and universal conquest, which rambles and +roves avidiously around all the realms of the future--let us go with all +our "devils" to the help of our "God"! It is probable that people will +misunderstand and mistake us on that account: what does it matter! They +will say: "Their 'honesty'--that is their devilry, and nothing else!" +What does it matter! And even if they were right--have not all Gods +hitherto been such sanctified, re-baptized devils? And after all, what +do we know of ourselves? And what the spirit that leads us wants TO BE +CALLED? (It is a question of names.) And how many spirits we harbour? +Our honesty, we free spirits--let us be careful lest it become our +vanity, our ornament and ostentation, our limitation, our stupidity! +Every virtue inclines to stupidity, every stupidity to virtue; "stupid +to the point of sanctity," they say in Russia,--let us be careful lest +out of pure honesty we eventually become saints and bores! Is not life +a hundred times too short for us--to bore ourselves? One would have to +believe in eternal life in order to... + +228. I hope to be forgiven for discovering that all moral philosophy +hitherto has been tedious and has belonged to the soporific +appliances--and that "virtue," in my opinion, has been MORE injured +by the TEDIOUSNESS of its advocates than by anything else; at the same +time, however, I would not wish to overlook their general usefulness. It +is desirable that as few people as possible should reflect upon morals, +and consequently it is very desirable that morals should not some day +become interesting! But let us not be afraid! Things still remain today +as they have always been: I see no one in Europe who has (or DISCLOSES) +an idea of the fact that philosophizing concerning morals might be +conducted in a dangerous, captious, and ensnaring manner--that CALAMITY +might be involved therein. Observe, for example, the indefatigable, +inevitable English utilitarians: how ponderously and respectably they +stalk on, stalk along (a Homeric metaphor expresses it better) in the +footsteps of Bentham, just as he had already stalked in the footsteps of +the respectable Helvetius! (no, he was not a dangerous man, Helvetius, +CE SENATEUR POCOCURANTE, to use an expression of Galiani). No new +thought, nothing of the nature of a finer turning or better expression +of an old thought, not even a proper history of what has been previously +thought on the subject: an IMPOSSIBLE literature, taking it all in all, +unless one knows how to leaven it with some mischief. In effect, the +old English vice called CANT, which is MORAL TARTUFFISM, has insinuated +itself also into these moralists (whom one must certainly read with an +eye to their motives if one MUST read them), concealed this time under +the new form of the scientific spirit; moreover, there is not absent +from them a secret struggle with the pangs of conscience, from which a +race of former Puritans must naturally suffer, in all their scientific +tinkering with morals. (Is not a moralist the opposite of a Puritan? +That is to say, as a thinker who regards morality as questionable, +as worthy of interrogation, in short, as a problem? Is moralizing +not-immoral?) In the end, they all want English morality to be +recognized as authoritative, inasmuch as mankind, or the "general +utility," or "the happiness of the greatest number,"--no! the happiness +of ENGLAND, will be best served thereby. They would like, by all means, +to convince themselves that the striving after English happiness, I +mean after COMFORT and FASHION (and in the highest instance, a seat in +Parliament), is at the same time the true path of virtue; in fact, that +in so far as there has been virtue in the world hitherto, it has +just consisted in such striving. Not one of those ponderous, +conscience-stricken herding-animals (who undertake to advocate the +cause of egoism as conducive to the general welfare) wants to have +any knowledge or inkling of the facts that the "general welfare" is +no ideal, no goal, no notion that can be at all grasped, but is only a +nostrum,--that what is fair to one MAY NOT at all be fair to another, +that the requirement of one morality for all is really a detriment to +higher men, in short, that there is a DISTINCTION OF RANK between man +and man, and consequently between morality and morality. They are an +unassuming and fundamentally mediocre species of men, these utilitarian +Englishmen, and, as already remarked, in so far as they are tedious, one +cannot think highly enough of their utility. One ought even to ENCOURAGE +them, as has been partially attempted in the following rhymes:-- + + Hail, ye worthies, barrow-wheeling, + "Longer--better," aye revealing, + + Stiffer aye in head and knee; + Unenraptured, never jesting, + Mediocre everlasting, + + SANS GENIE ET SANS ESPRIT! + + +229. In these later ages, which may be proud of their humanity, there +still remains so much fear, so much SUPERSTITION of the fear, of the +"cruel wild beast," the mastering of which constitutes the very pride of +these humaner ages--that even obvious truths, as if by the agreement +of centuries, have long remained unuttered, because they have the +appearance of helping the finally slain wild beast back to life again. +I perhaps risk something when I allow such a truth to escape; let +others capture it again and give it so much "milk of pious sentiment" +[FOOTNOTE: An expression from Schiller's William Tell, Act IV, Scene +3.] to drink, that it will lie down quiet and forgotten, in its old +corner.--One ought to learn anew about cruelty, and open one's eyes; +one ought at last to learn impatience, in order that such immodest +gross errors--as, for instance, have been fostered by ancient and +modern philosophers with regard to tragedy--may no longer wander about +virtuously and boldly. Almost everything that we call "higher culture" +is based upon the spiritualising and intensifying of CRUELTY--this is +my thesis; the "wild beast" has not been slain at all, it lives, it +flourishes, it has only been--transfigured. That which constitutes the +painful delight of tragedy is cruelty; that which operates agreeably in +so-called tragic sympathy, and at the basis even of everything sublime, +up to the highest and most delicate thrills of metaphysics, obtains its +sweetness solely from the intermingled ingredient of cruelty. What the +Roman enjoys in the arena, the Christian in the ecstasies of the cross, +the Spaniard at the sight of the faggot and stake, or of the bull-fight, +the present-day Japanese who presses his way to the tragedy, the workman +of the Parisian suburbs who has a homesickness for bloody revolutions, +the Wagnerienne who, with unhinged will, "undergoes" the performance of +"Tristan and Isolde"--what all these enjoy, and strive with mysterious +ardour to drink in, is the philtre of the great Circe "cruelty." Here, +to be sure, we must put aside entirely the blundering psychology of +former times, which could only teach with regard to cruelty that +it originated at the sight of the suffering of OTHERS: there is an +abundant, super-abundant enjoyment even in one's own suffering, in +causing one's own suffering--and wherever man has allowed himself to be +persuaded to self-denial in the RELIGIOUS sense, or to self-mutilation, +as among the Phoenicians and ascetics, or in general, to +desensualisation, decarnalisation, and contrition, to Puritanical +repentance-spasms, to vivisection of conscience and to Pascal-like +SACRIFIZIA DELL' INTELLETO, he is secretly allured and impelled +forwards by his cruelty, by the dangerous thrill of cruelty TOWARDS +HIMSELF.--Finally, let us consider that even the seeker of knowledge +operates as an artist and glorifier of cruelty, in that he compels his +spirit to perceive AGAINST its own inclination, and often enough against +the wishes of his heart:--he forces it to say Nay, where he would like +to affirm, love, and adore; indeed, every instance of taking a thing +profoundly and fundamentally, is a violation, an intentional injuring +of the fundamental will of the spirit, which instinctively aims at +appearance and superficiality,--even in every desire for knowledge there +is a drop of cruelty. + +230. Perhaps what I have said here about a "fundamental will of the +spirit" may not be understood without further details; I may be allowed +a word of explanation.--That imperious something which is popularly +called "the spirit," wishes to be master internally and externally, +and to feel itself master; it has the will of a multiplicity for a +simplicity, a binding, taming, imperious, and essentially ruling will. +Its requirements and capacities here, are the same as those assigned by +physiologists to everything that lives, grows, and multiplies. The power +of the spirit to appropriate foreign elements reveals itself in a strong +tendency to assimilate the new to the old, to simplify the manifold, +to overlook or repudiate the absolutely contradictory; just as it +arbitrarily re-underlines, makes prominent, and falsifies for itself +certain traits and lines in the foreign elements, in every portion of +the "outside world." Its object thereby is the incorporation of new +"experiences," the assortment of new things in the old arrangements--in +short, growth; or more properly, the FEELING of growth, the feeling of +increased power--is its object. This same will has at its service an +apparently opposed impulse of the spirit, a suddenly adopted preference +of ignorance, of arbitrary shutting out, a closing of windows, an inner +denial of this or that, a prohibition to approach, a sort of defensive +attitude against much that is knowable, a contentment with obscurity, +with the shutting-in horizon, an acceptance and approval of ignorance: +as that which is all necessary according to the degree of its +appropriating power, its "digestive power," to speak figuratively (and +in fact "the spirit" resembles a stomach more than anything else). Here +also belong an occasional propensity of the spirit to let itself be +deceived (perhaps with a waggish suspicion that it is NOT so and so, +but is only allowed to pass as such), a delight in uncertainty and +ambiguity, an exulting enjoyment of arbitrary, out-of-the-way narrowness +and mystery, of the too-near, of the foreground, of the magnified, +the diminished, the misshapen, the beautified--an enjoyment of the +arbitrariness of all these manifestations of power. Finally, in this +connection, there is the not unscrupulous readiness of the spirit to +deceive other spirits and dissemble before them--the constant pressing +and straining of a creating, shaping, changeable power: the spirit +enjoys therein its craftiness and its variety of disguises, it enjoys +also its feeling of security therein--it is precisely by its Protean +arts that it is best protected and concealed!--COUNTER TO this +propensity for appearance, for simplification, for a disguise, for a +cloak, in short, for an outside--for every outside is a cloak--there +operates the sublime tendency of the man of knowledge, which takes, and +INSISTS on taking things profoundly, variously, and thoroughly; as a +kind of cruelty of the intellectual conscience and taste, which every +courageous thinker will acknowledge in himself, provided, as it ought +to be, that he has sharpened and hardened his eye sufficiently long for +introspection, and is accustomed to severe discipline and even severe +words. He will say: "There is something cruel in the tendency of my +spirit": let the virtuous and amiable try to convince him that it is not +so! In fact, it would sound nicer, if, instead of our cruelty, perhaps +our "extravagant honesty" were talked about, whispered about, and +glorified--we free, VERY free spirits--and some day perhaps SUCH will +actually be our--posthumous glory! Meanwhile--for there is plenty of +time until then--we should be least inclined to deck ourselves out in +such florid and fringed moral verbiage; our whole former work has +just made us sick of this taste and its sprightly exuberance. They are +beautiful, glistening, jingling, festive words: honesty, love of truth, +love of wisdom, sacrifice for knowledge, heroism of the truthful--there +is something in them that makes one's heart swell with pride. But we +anchorites and marmots have long ago persuaded ourselves in all the +secrecy of an anchorite's conscience, that this worthy parade of +verbiage also belongs to the old false adornment, frippery, and +gold-dust of unconscious human vanity, and that even under such +flattering colour and repainting, the terrible original text HOMO NATURA +must again be recognized. In effect, to translate man back again into +nature; to master the many vain and visionary interpretations and +subordinate meanings which have hitherto been scratched and daubed over +the eternal original text, HOMO NATURA; to bring it about that man shall +henceforth stand before man as he now, hardened by the discipline +of science, stands before the OTHER forms of nature, with fearless +Oedipus-eyes, and stopped Ulysses-ears, deaf to the enticements of old +metaphysical bird-catchers, who have piped to him far too long: "Thou +art more! thou art higher! thou hast a different origin!"--this may be +a strange and foolish task, but that it is a TASK, who can deny! Why did +we choose it, this foolish task? Or, to put the question differently: +"Why knowledge at all?" Every one will ask us about this. And thus +pressed, we, who have asked ourselves the question a hundred times, have +not found and cannot find any better answer.... + +231. Learning alters us, it does what all nourishment does that does not +merely "conserve"--as the physiologist knows. But at the bottom of our +souls, quite "down below," there is certainly something unteachable, +a granite of spiritual fate, of predetermined decision and answer to +predetermined, chosen questions. In each cardinal problem there speaks +an unchangeable "I am this"; a thinker cannot learn anew about man and +woman, for instance, but can only learn fully--he can only follow to the +end what is "fixed" about them in himself. Occasionally we find certain +solutions of problems which make strong beliefs for us; perhaps they +are henceforth called "convictions." Later on--one sees in them only +footsteps to self-knowledge, guide-posts to the problem which we +ourselves ARE--or more correctly to the great stupidity which we embody, +our spiritual fate, the UNTEACHABLE in us, quite "down below."--In view +of this liberal compliment which I have just paid myself, permission +will perhaps be more readily allowed me to utter some truths about +"woman as she is," provided that it is known at the outset how literally +they are merely--MY truths. + +232. Woman wishes to be independent, and therefore she begins to +enlighten men about "woman as she is"--THIS is one of the worst +developments of the general UGLIFYING of Europe. For what must these +clumsy attempts of feminine scientificality and self-exposure bring +to light! Woman has so much cause for shame; in woman there is so +much pedantry, superficiality, schoolmasterliness, petty presumption, +unbridledness, and indiscretion concealed--study only woman's behaviour +towards children!--which has really been best restrained and dominated +hitherto by the FEAR of man. Alas, if ever the "eternally tedious in +woman"--she has plenty of it!--is allowed to venture forth! if she +begins radically and on principle to unlearn her wisdom and art-of +charming, of playing, of frightening away sorrow, of alleviating and +taking easily; if she forgets her delicate aptitude for agreeable +desires! Female voices are already raised, which, by Saint Aristophanes! +make one afraid:--with medical explicitness it is stated in a +threatening manner what woman first and last REQUIRES from man. Is +it not in the very worst taste that woman thus sets herself up to be +scientific? Enlightenment hitherto has fortunately been men's affair, +men's gift--we remained therewith "among ourselves"; and in the end, +in view of all that women write about "woman," we may well have +considerable doubt as to whether woman really DESIRES enlightenment +about herself--and CAN desire it. If woman does not thereby seek a new +ORNAMENT for herself--I believe ornamentation belongs to the eternally +feminine?--why, then, she wishes to make herself feared: perhaps she +thereby wishes to get the mastery. But she does not want truth--what +does woman care for truth? From the very first, nothing is more foreign, +more repugnant, or more hostile to woman than truth--her great art is +falsehood, her chief concern is appearance and beauty. Let us confess +it, we men: we honour and love this very art and this very instinct in +woman: we who have the hard task, and for our recreation gladly seek the +company of beings under whose hands, glances, and delicate follies, our +seriousness, our gravity, and profundity appear almost like follies to +us. Finally, I ask the question: Did a woman herself ever acknowledge +profundity in a woman's mind, or justice in a woman's heart? And is it +not true that on the whole "woman" has hitherto been most despised by +woman herself, and not at all by us?--We men desire that woman should +not continue to compromise herself by enlightening us; just as it was +man's care and the consideration for woman, when the church decreed: +mulier taceat in ecclesia. It was to the benefit of woman when Napoleon +gave the too eloquent Madame de Stael to understand: mulier taceat in +politicis!--and in my opinion, he is a true friend of woman who calls +out to women today: mulier taceat de mulierel. + +233. It betrays corruption of the instincts--apart from the fact that +it betrays bad taste--when a woman refers to Madame Roland, or Madame de +Stael, or Monsieur George Sand, as though something were proved thereby +in favour of "woman as she is." Among men, these are the three comical +women as they are--nothing more!--and just the best involuntary +counter-arguments against feminine emancipation and autonomy. + +234. Stupidity in the kitchen; woman as cook; the terrible +thoughtlessness with which the feeding of the family and the master of +the house is managed! Woman does not understand what food means, and she +insists on being cook! If woman had been a thinking creature, she should +certainly, as cook for thousands of years, have discovered the most +important physiological facts, and should likewise have got possession +of the healing art! Through bad female cooks--through the entire lack +of reason in the kitchen--the development of mankind has been longest +retarded and most interfered with: even today matters are very little +better. A word to High School girls. + +235. There are turns and casts of fancy, there are sentences, little +handfuls of words, in which a whole culture, a whole society suddenly +crystallises itself. Among these is the incidental remark of Madame de +Lambert to her son: "MON AMI, NE VOUS PERMETTEZ JAMAIS QUE DES FOLIES, +QUI VOUS FERONT GRAND PLAISIR"--the motherliest and wisest remark, by +the way, that was ever addressed to a son. + +236. I have no doubt that every noble woman will oppose what Dante and +Goethe believed about woman--the former when he sang, "ELLA GUARDAVA +SUSO, ED IO IN LEI," and the latter when he interpreted it, "the +eternally feminine draws us ALOFT"; for THIS is just what she believes +of the eternally masculine. + +237. + +SEVEN APOPHTHEGMS FOR WOMEN + +How the longest ennui flees, When a man comes to our knees! + +Age, alas! and science staid, Furnish even weak virtue aid. + +Sombre garb and silence meet: Dress for every dame--discreet. + +Whom I thank when in my bliss? God!--and my good tailoress! + +Young, a flower-decked cavern home; Old, a dragon thence doth roam. + +Noble title, leg that's fine, Man as well: Oh, were HE mine! + +Speech in brief and sense in mass--Slippery for the jenny-ass! + +237A. Woman has hitherto been treated by men like birds, which, losing +their way, have come down among them from an elevation: as something +delicate, fragile, wild, strange, sweet, and animating--but as something +also which must be cooped up to prevent it flying away. + +238. To be mistaken in the fundamental problem of "man and woman," to +deny here the profoundest antagonism and the necessity for an eternally +hostile tension, to dream here perhaps of equal rights, equal +training, equal claims and obligations: that is a TYPICAL sign of +shallow-mindedness; and a thinker who has proved himself shallow at +this dangerous spot--shallow in instinct!--may generally be regarded as +suspicious, nay more, as betrayed, as discovered; he will probably prove +too "short" for all fundamental questions of life, future as well as +present, and will be unable to descend into ANY of the depths. On the +other hand, a man who has depth of spirit as well as of desires, and +has also the depth of benevolence which is capable of severity and +harshness, and easily confounded with them, can only think of woman as +ORIENTALS do: he must conceive of her as a possession, as confinable +property, as a being predestined for service and accomplishing her +mission therein--he must take his stand in this matter upon the immense +rationality of Asia, upon the superiority of the instinct of Asia, as +the Greeks did formerly; those best heirs and scholars of Asia--who, +as is well known, with their INCREASING culture and amplitude of power, +from Homer to the time of Pericles, became gradually STRICTER towards +woman, in short, more Oriental. HOW necessary, HOW logical, even HOW +humanely desirable this was, let us consider for ourselves! + +239. The weaker sex has in no previous age been treated with so +much respect by men as at present--this belongs to the tendency and +fundamental taste of democracy, in the same way as disrespectfulness to +old age--what wonder is it that abuse should be immediately made of +this respect? They want more, they learn to make claims, the tribute +of respect is at last felt to be well-nigh galling; rivalry for rights, +indeed actual strife itself, would be preferred: in a word, woman is +losing modesty. And let us immediately add that she is also losing +taste. She is unlearning to FEAR man: but the woman who "unlearns to +fear" sacrifices her most womanly instincts. That woman should venture +forward when the fear-inspiring quality in man--or more definitely, +the MAN in man--is no longer either desired or fully developed, is +reasonable enough and also intelligible enough; what is more difficult +to understand is that precisely thereby--woman deteriorates. This is +what is happening nowadays: let us not deceive ourselves about it! +Wherever the industrial spirit has triumphed over the military +and aristocratic spirit, woman strives for the economic and legal +independence of a clerk: "woman as clerkess" is inscribed on the portal +of the modern society which is in course of formation. While she +thus appropriates new rights, aspires to be "master," and inscribes +"progress" of woman on her flags and banners, the very opposite realises +itself with terrible obviousness: WOMAN RETROGRADES. Since the French +Revolution the influence of woman in Europe has DECLINED in proportion +as she has increased her rights and claims; and the "emancipation of +woman," insofar as it is desired and demanded by women themselves (and +not only by masculine shallow-pates), thus proves to be a remarkable +symptom of the increased weakening and deadening of the most womanly +instincts. There is STUPIDITY in this movement, an almost masculine +stupidity, of which a well-reared woman--who is always a sensible +woman--might be heartily ashamed. To lose the intuition as to the ground +upon which she can most surely achieve victory; to neglect exercise in +the use of her proper weapons; to let-herself-go before man, perhaps +even "to the book," where formerly she kept herself in control and in +refined, artful humility; to neutralize with her virtuous audacity man's +faith in a VEILED, fundamentally different ideal in woman, something +eternally, necessarily feminine; to emphatically and loquaciously +dissuade man from the idea that woman must be preserved, cared for, +protected, and indulged, like some delicate, strangely wild, and +often pleasant domestic animal; the clumsy and indignant collection of +everything of the nature of servitude and bondage which the position of +woman in the hitherto existing order of society has entailed and still +entails (as though slavery were a counter-argument, and not rather a +condition of every higher culture, of every elevation of culture):--what +does all this betoken, if not a disintegration of womanly instincts, +a defeminising? Certainly, there are enough of idiotic friends and +corrupters of woman among the learned asses of the masculine sex, who +advise woman to defeminize herself in this manner, and to imitate +all the stupidities from which "man" in Europe, European "manliness," +suffers,--who would like to lower woman to "general culture," indeed +even to newspaper reading and meddling with politics. Here and there +they wish even to make women into free spirits and literary workers: as +though a woman without piety would not be something perfectly obnoxious +or ludicrous to a profound and godless man;--almost everywhere her +nerves are being ruined by the most morbid and dangerous kind of music +(our latest German music), and she is daily being made more hysterical +and more incapable of fulfilling her first and last function, that of +bearing robust children. They wish to "cultivate" her in general still +more, and intend, as they say, to make the "weaker sex" STRONG by +culture: as if history did not teach in the most emphatic manner that +the "cultivating" of mankind and his weakening--that is to say, the +weakening, dissipating, and languishing of his FORCE OF WILL--have +always kept pace with one another, and that the most powerful and +influential women in the world (and lastly, the mother of Napoleon) +had just to thank their force of will--and not their schoolmasters--for +their power and ascendancy over men. That which inspires respect +in woman, and often enough fear also, is her NATURE, which is more +"natural" than that of man, her genuine, carnivora-like, cunning +flexibility, her tiger-claws beneath the glove, her NAIVETE in egoism, +her untrainableness and innate wildness, the incomprehensibleness, +extent, and deviation of her desires and virtues. That which, in spite +of fear, excites one's sympathy for the dangerous and beautiful cat, +"woman," is that she seems more afflicted, more vulnerable, more +necessitous of love, and more condemned to disillusionment than any +other creature. Fear and sympathy it is with these feelings that man has +hitherto stood in the presence of woman, always with one foot already in +tragedy, which rends while it delights--What? And all that is now to +be at an end? And the DISENCHANTMENT of woman is in progress? The +tediousness of woman is slowly evolving? Oh Europe! Europe! We know +the horned animal which was always most attractive to thee, from which +danger is ever again threatening thee! Thy old fable might once more +become "history"--an immense stupidity might once again overmaster +thee and carry thee away! And no God concealed beneath it--no! only an +"idea," a "modern idea"! + + + +CHAPTER VIII. PEOPLES AND COUNTRIES + + +240. I HEARD, once again for the first time, Richard Wagner's overture +to the Mastersinger: it is a piece of magnificent, gorgeous, heavy, +latter-day art, which has the pride to presuppose two centuries of music +as still living, in order that it may be understood:--it is an honour +to Germans that such a pride did not miscalculate! What flavours +and forces, what seasons and climes do we not find mingled in it! It +impresses us at one time as ancient, at another time as foreign, bitter, +and too modern, it is as arbitrary as it is pompously traditional, it +is not infrequently roguish, still oftener rough and coarse--it has fire +and courage, and at the same time the loose, dun-coloured skin of fruits +which ripen too late. It flows broad and full: and suddenly there is a +moment of inexplicable hesitation, like a gap that opens between cause +and effect, an oppression that makes us dream, almost a nightmare; but +already it broadens and widens anew, the old stream of delight--the most +manifold delight,--of old and new happiness; including ESPECIALLY +the joy of the artist in himself, which he refuses to conceal, his +astonished, happy cognizance of his mastery of the expedients here +employed, the new, newly acquired, imperfectly tested expedients of art +which he apparently betrays to us. All in all, however, no beauty, no +South, nothing of the delicate southern clearness of the sky, nothing +of grace, no dance, hardly a will to logic; a certain clumsiness even, +which is also emphasized, as though the artist wished to say to us: "It +is part of my intention"; a cumbersome drapery, something arbitrarily +barbaric and ceremonious, a flirring of learned and venerable conceits +and witticisms; something German in the best and worst sense of +the word, something in the German style, manifold, formless, and +inexhaustible; a certain German potency and super-plenitude of +soul, which is not afraid to hide itself under the RAFFINEMENTS of +decadence--which, perhaps, feels itself most at ease there; a real, +genuine token of the German soul, which is at the same time young and +aged, too ripe and yet still too rich in futurity. This kind of music +expresses best what I think of the Germans: they belong to the day +before yesterday and the day after tomorrow--THEY HAVE AS YET NO TODAY. + +241. We "good Europeans," we also have hours when we allow ourselves a +warm-hearted patriotism, a plunge and relapse into old loves and narrow +views--I have just given an example of it--hours of national excitement, +of patriotic anguish, and all other sorts of old-fashioned floods of +sentiment. Duller spirits may perhaps only get done with what confines +its operations in us to hours and plays itself out in hours--in a +considerable time: some in half a year, others in half a lifetime, +according to the speed and strength with which they digest and "change +their material." Indeed, I could think of sluggish, hesitating races, +which even in our rapidly moving Europe, would require half a century +ere they could surmount such atavistic attacks of patriotism and +soil-attachment, and return once more to reason, that is to say, to +"good Europeanism." And while digressing on this possibility, I +happen to become an ear-witness of a conversation between two old +patriots--they were evidently both hard of hearing and consequently +spoke all the louder. "HE has as much, and knows as much, philosophy as +a peasant or a corps-student," said the one--"he is still innocent. But +what does that matter nowadays! It is the age of the masses: they lie on +their belly before everything that is massive. And so also in politicis. +A statesman who rears up for them a new Tower of Babel, some monstrosity +of empire and power, they call 'great'--what does it matter that we more +prudent and conservative ones do not meanwhile give up the old belief +that it is only the great thought that gives greatness to an action or +affair. Supposing a statesman were to bring his people into the position +of being obliged henceforth to practise 'high politics,' for which they +were by nature badly endowed and prepared, so that they would have +to sacrifice their old and reliable virtues, out of love to a new and +doubtful mediocrity;--supposing a statesman were to condemn his people +generally to 'practise politics,' when they have hitherto had something +better to do and think about, and when in the depths of their souls +they have been unable to free themselves from a prudent loathing of +the restlessness, emptiness, and noisy wranglings of the essentially +politics-practising nations;--supposing such a statesman were to +stimulate the slumbering passions and avidities of his people, were to +make a stigma out of their former diffidence and delight in aloofness, +an offence out of their exoticism and hidden permanency, were to +depreciate their most radical proclivities, subvert their consciences, +make their minds narrow, and their tastes 'national'--what! a statesman +who should do all this, which his people would have to do penance for +throughout their whole future, if they had a future, such a statesman +would be GREAT, would he?"--"Undoubtedly!" replied the other old patriot +vehemently, "otherwise he COULD NOT have done it! It was mad perhaps to +wish such a thing! But perhaps everything great has been just as mad +at its commencement!"--"Misuse of words!" cried his interlocutor, +contradictorily--"strong! strong! Strong and mad! NOT great!"--The old +men had obviously become heated as they thus shouted their "truths" in +each other's faces, but I, in my happiness and apartness, considered how +soon a stronger one may become master of the strong, and also that +there is a compensation for the intellectual superficialising of a +nation--namely, in the deepening of another. + +242. Whether we call it "civilization," or "humanising," or "progress," +which now distinguishes the European, whether we call it simply, without +praise or blame, by the political formula the DEMOCRATIC movement in +Europe--behind all the moral and political foregrounds pointed to by +such formulas, an immense PHYSIOLOGICAL PROCESS goes on, which is ever +extending the process of the assimilation of Europeans, their +increasing detachment from the conditions under which, climatically and +hereditarily, united races originate, their increasing independence of +every definite milieu, that for centuries would fain inscribe itself +with equal demands on soul and body,--that is to say, the slow emergence +of an essentially SUPER-NATIONAL and nomadic species of man, who +possesses, physiologically speaking, a maximum of the art and power +of adaptation as his typical distinction. This process of the EVOLVING +EUROPEAN, which can be retarded in its TEMPO by great relapses, but +will perhaps just gain and grow thereby in vehemence and depth--the +still-raging storm and stress of "national sentiment" pertains to it, +and also the anarchism which is appearing at present--this process +will probably arrive at results on which its naive propagators and +panegyrists, the apostles of "modern ideas," would least care to reckon. +The same new conditions under which on an average a levelling and +mediocrising of man will take place--a useful, industrious, variously +serviceable, and clever gregarious man--are in the highest degree +suitable to give rise to exceptional men of the most dangerous and +attractive qualities. For, while the capacity for adaptation, which is +every day trying changing conditions, and begins a new work with every +generation, almost with every decade, makes the POWERFULNESS of the type +impossible; while the collective impression of such future Europeans +will probably be that of numerous, talkative, weak-willed, and very +handy workmen who REQUIRE a master, a commander, as they require their +daily bread; while, therefore, the democratising of Europe will tend to +the production of a type prepared for SLAVERY in the most subtle +sense of the term: the STRONG man will necessarily in individual and +exceptional cases, become stronger and richer than he has perhaps ever +been before--owing to the unprejudicedness of his schooling, owing to +the immense variety of practice, art, and disguise. I meant to say +that the democratising of Europe is at the same time an involuntary +arrangement for the rearing of TYRANTS--taking the word in all its +meanings, even in its most spiritual sense. + +243. I hear with pleasure that our sun is moving rapidly towards the +constellation Hercules: and I hope that the men on this earth will do +like the sun. And we foremost, we good Europeans! + +244. There was a time when it was customary to call Germans "deep" +by way of distinction; but now that the most successful type of new +Germanism is covetous of quite other honours, and perhaps misses +"smartness" in all that has depth, it is almost opportune and patriotic +to doubt whether we did not formerly deceive ourselves with that +commendation: in short, whether German depth is not at bottom something +different and worse--and something from which, thank God, we are on the +point of successfully ridding ourselves. Let us try, then, to relearn +with regard to German depth; the only thing necessary for the purpose is +a little vivisection of the German soul.--The German soul is above all +manifold, varied in its source, aggregated and super-imposed, rather +than actually built: this is owing to its origin. A German who would +embolden himself to assert: "Two souls, alas, dwell in my breast," would +make a bad guess at the truth, or, more correctly, he would come far +short of the truth about the number of souls. As a people made up of +the most extraordinary mixing and mingling of races, perhaps even with a +preponderance of the pre-Aryan element as the "people of the centre" in +every sense of the term, the Germans are more intangible, more ample, +more contradictory, more unknown, more incalculable, more surprising, +and even more terrifying than other peoples are to themselves:--they +escape DEFINITION, and are thereby alone the despair of the French. It +IS characteristic of the Germans that the question: "What is German?" +never dies out among them. Kotzebue certainly knew his Germans well +enough: "We are known," they cried jubilantly to him--but Sand also +thought he knew them. Jean Paul knew what he was doing when he declared +himself incensed at Fichte's lying but patriotic flatteries and +exaggerations,--but it is probable that Goethe thought differently about +Germans from Jean Paul, even though he acknowledged him to be right with +regard to Fichte. It is a question what Goethe really thought about the +Germans?--But about many things around him he never spoke explicitly, +and all his life he knew how to keep an astute silence--probably he +had good reason for it. It is certain that it was not the "Wars of +Independence" that made him look up more joyfully, any more than it was +the French Revolution,--the event on account of which he RECONSTRUCTED +his "Faust," and indeed the whole problem of "man," was the appearance +of Napoleon. There are words of Goethe in which he condemns with +impatient severity, as from a foreign land, that which Germans take a +pride in, he once defined the famous German turn of mind as "Indulgence +towards its own and others' weaknesses." Was he wrong? it is +characteristic of Germans that one is seldom entirely wrong about them. +The German soul has passages and galleries in it, there are caves, +hiding-places, and dungeons therein, its disorder has much of the charm +of the mysterious, the German is well acquainted with the bypaths to +chaos. And as everything loves its symbol, so the German loves the +clouds and all that is obscure, evolving, crepuscular, damp, and +shrouded, it seems to him that everything uncertain, undeveloped, +self-displacing, and growing is "deep". The German himself does not +EXIST, he is BECOMING, he is "developing himself". "Development" is +therefore the essentially German discovery and hit in the great domain +of philosophical formulas,--a ruling idea, which, together with German +beer and German music, is labouring to Germanise all Europe. Foreigners +are astonished and attracted by the riddles which the conflicting nature +at the basis of the German soul propounds to them (riddles which +Hegel systematised and Richard Wagner has in the end set to music). +"Good-natured and spiteful"--such a juxtaposition, preposterous in the +case of every other people, is unfortunately only too often justified +in Germany one has only to live for a while among Swabians to know this! +The clumsiness of the German scholar and his social distastefulness +agree alarmingly well with his physical rope-dancing and nimble +boldness, of which all the Gods have learnt to be afraid. If any one +wishes to see the "German soul" demonstrated ad oculos, let him +only look at German taste, at German arts and manners what boorish +indifference to "taste"! How the noblest and the commonest stand there +in juxtaposition! How disorderly and how rich is the whole constitution +of this soul! The German DRAGS at his soul, he drags at everything he +experiences. He digests his events badly; he never gets "done" +with them; and German depth is often only a difficult, hesitating +"digestion." And just as all chronic invalids, all dyspeptics like what +is convenient, so the German loves "frankness" and "honesty"; it is +so CONVENIENT to be frank and honest!--This confidingness, this +complaisance, this showing-the-cards of German HONESTY, is probably the +most dangerous and most successful disguise which the German is up to +nowadays: it is his proper Mephistophelean art; with this he can "still +achieve much"! The German lets himself go, and thereby gazes with +faithful, blue, empty German eyes--and other countries immediately +confound him with his dressing-gown!--I meant to say that, let "German +depth" be what it will--among ourselves alone we perhaps take the +liberty to laugh at it--we shall do well to continue henceforth to +honour its appearance and good name, and not barter away too cheaply our +old reputation as a people of depth for Prussian "smartness," and +Berlin wit and sand. It is wise for a people to pose, and LET itself +be regarded, as profound, clumsy, good-natured, honest, and foolish: it +might even be--profound to do so! Finally, we should do honour to +our name--we are not called the "TIUSCHE VOLK" (deceptive people) for +nothing.... + +245. The "good old" time is past, it sang itself out in Mozart--how +happy are WE that his ROCOCO still speaks to us, that his "good +company," his tender enthusiasm, his childish delight in the Chinese and +its flourishes, his courtesy of heart, his longing for the elegant, the +amorous, the tripping, the tearful, and his belief in the South, can +still appeal to SOMETHING LEFT in us! Ah, some time or other it will be +over with it!--but who can doubt that it will be over still sooner with +the intelligence and taste for Beethoven! For he was only the last echo +of a break and transition in style, and NOT, like Mozart, the last echo +of a great European taste which had existed for centuries. Beethoven +is the intermediate event between an old mellow soul that is constantly +breaking down, and a future over-young soul that is always COMING; +there is spread over his music the twilight of eternal loss and eternal +extravagant hope,--the same light in which Europe was bathed when it +dreamed with Rousseau, when it danced round the Tree of Liberty of the +Revolution, and finally almost fell down in adoration before Napoleon. +But how rapidly does THIS very sentiment now pale, how difficult +nowadays is even the APPREHENSION of this sentiment, how strangely does +the language of Rousseau, Schiller, Shelley, and Byron sound to our ear, +in whom COLLECTIVELY the same fate of Europe was able to SPEAK, which +knew how to SING in Beethoven!--Whatever German music came afterwards, +belongs to Romanticism, that is to say, to a movement which, +historically considered, was still shorter, more fleeting, and more +superficial than that great interlude, the transition of Europe from +Rousseau to Napoleon, and to the rise of democracy. Weber--but what do +WE care nowadays for "Freischutz" and "Oberon"! Or Marschner's "Hans +Heiling" and "Vampyre"! Or even Wagner's "Tannhauser"! That is extinct, +although not yet forgotten music. This whole music of Romanticism, +besides, was not noble enough, was not musical enough, to maintain its +position anywhere but in the theatre and before the masses; from the +beginning it was second-rate music, which was little thought of by +genuine musicians. It was different with Felix Mendelssohn, that halcyon +master, who, on account of his lighter, purer, happier soul, quickly +acquired admiration, and was equally quickly forgotten: as the beautiful +EPISODE of German music. But with regard to Robert Schumann, who took +things seriously, and has been taken seriously from the first--he +was the last that founded a school,--do we not now regard it as a +satisfaction, a relief, a deliverance, that this very Romanticism +of Schumann's has been surmounted? Schumann, fleeing into the "Saxon +Switzerland" of his soul, with a half Werther-like, half Jean-Paul-like +nature (assuredly not like Beethoven! assuredly not like Byron!)--his +MANFRED music is a mistake and a misunderstanding to the extent of +injustice; Schumann, with his taste, which was fundamentally a PETTY +taste (that is to say, a dangerous propensity--doubly dangerous among +Germans--for quiet lyricism and intoxication of the feelings), going +constantly apart, timidly withdrawing and retiring, a noble weakling who +revelled in nothing but anonymous joy and sorrow, from the beginning +a sort of girl and NOLI ME TANGERE--this Schumann was already merely a +GERMAN event in music, and no longer a European event, as Beethoven had +been, as in a still greater degree Mozart had been; with Schumann German +music was threatened with its greatest danger, that of LOSING THE VOICE +FOR THE SOUL OF EUROPE and sinking into a merely national affair. + +246. What a torture are books written in German to a reader who has a +THIRD ear! How indignantly he stands beside the slowly turning swamp +of sounds without tune and rhythms without dance, which Germans call +a "book"! And even the German who READS books! How lazily, how +reluctantly, how badly he reads! How many Germans know, and consider it +obligatory to know, that there is ART in every good sentence--art which +must be divined, if the sentence is to be understood! If there is a +misunderstanding about its TEMPO, for instance, the sentence itself +is misunderstood! That one must not be doubtful about the +rhythm-determining syllables, that one should feel the breaking of the +too-rigid symmetry as intentional and as a charm, that one should lend a +fine and patient ear to every STACCATO and every RUBATO, that one should +divine the sense in the sequence of the vowels and diphthongs, and how +delicately and richly they can be tinted and retinted in the order of +their arrangement--who among book-reading Germans is complaisant enough +to recognize such duties and requirements, and to listen to so much art +and intention in language? After all, one just "has no ear for it"; +and so the most marked contrasts of style are not heard, and the most +delicate artistry is as it were SQUANDERED on the deaf.--These were my +thoughts when I noticed how clumsily and unintuitively two masters in +the art of prose-writing have been confounded: one, whose words drop +down hesitatingly and coldly, as from the roof of a damp cave--he counts +on their dull sound and echo; and another who manipulates his language +like a flexible sword, and from his arm down into his toes feels the +dangerous bliss of the quivering, over-sharp blade, which wishes to +bite, hiss, and cut. + +247. How little the German style has to do with harmony and with the +ear, is shown by the fact that precisely our good musicians themselves +write badly. The German does not read aloud, he does not read for the +ear, but only with his eyes; he has put his ears away in the drawer for +the time. In antiquity when a man read--which was seldom enough--he read +something to himself, and in a loud voice; they were surprised when +any one read silently, and sought secretly the reason of it. In a +loud voice: that is to say, with all the swellings, inflections, and +variations of key and changes of TEMPO, in which the ancient PUBLIC +world took delight. The laws of the written style were then the same +as those of the spoken style; and these laws depended partly on the +surprising development and refined requirements of the ear and larynx; +partly on the strength, endurance, and power of the ancient lungs. In +the ancient sense, a period is above all a physiological whole, inasmuch +as it is comprised in one breath. Such periods as occur in Demosthenes +and Cicero, swelling twice and sinking twice, and all in one breath, +were pleasures to the men of ANTIQUITY, who knew by their own schooling +how to appreciate the virtue therein, the rareness and the difficulty +in the deliverance of such a period;--WE have really no right to the +BIG period, we modern men, who are short of breath in every sense! Those +ancients, indeed, were all of them dilettanti in speaking, consequently +connoisseurs, consequently critics--they thus brought their orators to +the highest pitch; in the same manner as in the last century, when all +Italian ladies and gentlemen knew how to sing, the virtuosoship of song +(and with it also the art of melody) reached its elevation. In Germany, +however (until quite recently when a kind of platform eloquence began +shyly and awkwardly enough to flutter its young wings), there was +properly speaking only one kind of public and APPROXIMATELY artistical +discourse--that delivered from the pulpit. The preacher was the only one +in Germany who knew the weight of a syllable or a word, in what manner a +sentence strikes, springs, rushes, flows, and comes to a close; he alone +had a conscience in his ears, often enough a bad conscience: for reasons +are not lacking why proficiency in oratory should be especially seldom +attained by a German, or almost always too late. The masterpiece of +German prose is therefore with good reason the masterpiece of its +greatest preacher: the BIBLE has hitherto been the best German +book. Compared with Luther's Bible, almost everything else is merely +"literature"--something which has not grown in Germany, and therefore +has not taken and does not take root in German hearts, as the Bible has +done. + +248. There are two kinds of geniuses: one which above all engenders and +seeks to engender, and another which willingly lets itself be fructified +and brings forth. And similarly, among the gifted nations, there are +those on whom the woman's problem of pregnancy has devolved, and the +secret task of forming, maturing, and perfecting--the Greeks, for +instance, were a nation of this kind, and so are the French; and others +which have to fructify and become the cause of new modes of life--like +the Jews, the Romans, and, in all modesty be it asked: like the +Germans?--nations tortured and enraptured by unknown fevers and +irresistibly forced out of themselves, amorous and longing for +foreign races (for such as "let themselves be fructified"), and withal +imperious, like everything conscious of being full of generative force, +and consequently empowered "by the grace of God." These two kinds of +geniuses seek each other like man and woman; but they also misunderstand +each other--like man and woman. + +249. Every nation has its own "Tartuffery," and calls that its +virtue.--One does not know--cannot know, the best that is in one. + +250. What Europe owes to the Jews?--Many things, good and bad, and above +all one thing of the nature both of the best and the worst: the grand +style in morality, the fearfulness and majesty of infinite demands, of +infinite significations, the whole Romanticism and sublimity of moral +questionableness--and consequently just the most attractive, ensnaring, +and exquisite element in those iridescences and allurements to life, +in the aftersheen of which the sky of our European culture, its evening +sky, now glows--perhaps glows out. For this, we artists among the +spectators and philosophers, are--grateful to the Jews. + +251. It must be taken into the bargain, if various clouds and +disturbances--in short, slight attacks of stupidity--pass over the +spirit of a people that suffers and WANTS to suffer from national +nervous fever and political ambition: for instance, among present-day +Germans there is alternately the anti-French folly, the anti-Semitic +folly, the anti-Polish folly, the Christian-romantic folly, the +Wagnerian folly, the Teutonic folly, the Prussian folly (just look at +those poor historians, the Sybels and Treitschkes, and their closely +bandaged heads), and whatever else these little obscurations of the +German spirit and conscience may be called. May it be forgiven me that +I, too, when on a short daring sojourn on very infected ground, did not +remain wholly exempt from the disease, but like every one else, began +to entertain thoughts about matters which did not concern me--the first +symptom of political infection. About the Jews, for instance, listen +to the following:--I have never yet met a German who was favourably +inclined to the Jews; and however decided the repudiation of actual +anti-Semitism may be on the part of all prudent and political men, this +prudence and policy is not perhaps directed against the nature of the +sentiment itself, but only against its dangerous excess, and especially +against the distasteful and infamous expression of this excess of +sentiment;--on this point we must not deceive ourselves. That Germany +has amply SUFFICIENT Jews, that the German stomach, the German blood, +has difficulty (and will long have difficulty) in disposing only of this +quantity of "Jew"--as the Italian, the Frenchman, and the Englishman +have done by means of a stronger digestion:--that is the unmistakable +declaration and language of a general instinct, to which one must listen +and according to which one must act. "Let no more Jews come in! And shut +the doors, especially towards the East (also towards Austria)!"--thus +commands the instinct of a people whose nature is still feeble and +uncertain, so that it could be easily wiped out, easily extinguished, by +a stronger race. The Jews, however, are beyond all doubt the strongest, +toughest, and purest race at present living in Europe, they know how +to succeed even under the worst conditions (in fact better than under +favourable ones), by means of virtues of some sort, which one would like +nowadays to label as vices--owing above all to a resolute faith which +does not need to be ashamed before "modern ideas", they alter only, +WHEN they do alter, in the same way that the Russian Empire makes +its conquest--as an empire that has plenty of time and is not of +yesterday--namely, according to the principle, "as slowly as possible"! +A thinker who has the future of Europe at heart, will, in all his +perspectives concerning the future, calculate upon the Jews, as he +will calculate upon the Russians, as above all the surest and likeliest +factors in the great play and battle of forces. That which is at present +called a "nation" in Europe, and is really rather a RES FACTA than NATA +(indeed, sometimes confusingly similar to a RES FICTA ET PICTA), is in +every case something evolving, young, easily displaced, and not yet +a race, much less such a race AERE PERENNUS, as the Jews are such +"nations" should most carefully avoid all hot-headed rivalry and +hostility! It is certain that the Jews, if they desired--or if they +were driven to it, as the anti-Semites seem to wish--COULD now have the +ascendancy, nay, literally the supremacy, over Europe, that they are NOT +working and planning for that end is equally certain. Meanwhile, they +rather wish and desire, even somewhat importunely, to be insorbed and +absorbed by Europe, they long to be finally settled, authorized, and +respected somewhere, and wish to put an end to the nomadic life, to the +"wandering Jew",--and one should certainly take account of this impulse +and tendency, and MAKE ADVANCES to it (it possibly betokens a mitigation +of the Jewish instincts) for which purpose it would perhaps be useful +and fair to banish the anti-Semitic bawlers out of the country. One +should make advances with all prudence, and with selection, pretty much +as the English nobility do It stands to reason that the more powerful +and strongly marked types of new Germanism could enter into relation +with the Jews with the least hesitation, for instance, the nobleman +officer from the Prussian border it would be interesting in many ways +to see whether the genius for money and patience (and especially some +intellect and intellectuality--sadly lacking in the place referred to) +could not in addition be annexed and trained to the hereditary art of +commanding and obeying--for both of which the country in question has +now a classic reputation But here it is expedient to break off my festal +discourse and my sprightly Teutonomania for I have already reached my +SERIOUS TOPIC, the "European problem," as I understand it, the rearing +of a new ruling caste for Europe. + +252. They are not a philosophical race--the English: Bacon represents an +ATTACK on the philosophical spirit generally, Hobbes, Hume, and Locke, +an abasement, and a depreciation of the idea of a "philosopher" for more +than a century. It was AGAINST Hume that Kant uprose and raised himself; +it was Locke of whom Schelling RIGHTLY said, "JE MEPRISE LOCKE"; in the +struggle against the English mechanical stultification of the world, +Hegel and Schopenhauer (along with Goethe) were of one accord; the +two hostile brother-geniuses in philosophy, who pushed in different +directions towards the opposite poles of German thought, and thereby +wronged each other as only brothers will do.--What is lacking in +England, and has always been lacking, that half-actor and rhetorician +knew well enough, the absurd muddle-head, Carlyle, who sought to conceal +under passionate grimaces what he knew about himself: namely, what was +LACKING in Carlyle--real POWER of intellect, real DEPTH of intellectual +perception, in short, philosophy. It is characteristic of such an +unphilosophical race to hold on firmly to Christianity--they NEED its +discipline for "moralizing" and humanizing. The Englishman, more gloomy, +sensual, headstrong, and brutal than the German--is for that very +reason, as the baser of the two, also the most pious: he has all the +MORE NEED of Christianity. To finer nostrils, this English Christianity +itself has still a characteristic English taint of spleen and alcoholic +excess, for which, owing to good reasons, it is used as an antidote--the +finer poison to neutralize the coarser: a finer form of poisoning is +in fact a step in advance with coarse-mannered people, a step towards +spiritualization. The English coarseness and rustic demureness is still +most satisfactorily disguised by Christian pantomime, and by praying +and psalm-singing (or, more correctly, it is thereby explained and +differently expressed); and for the herd of drunkards and rakes who +formerly learned moral grunting under the influence of Methodism (and +more recently as the "Salvation Army"), a penitential fit may really be +the relatively highest manifestation of "humanity" to which they can +be elevated: so much may reasonably be admitted. That, however, which +offends even in the humanest Englishman is his lack of music, to speak +figuratively (and also literally): he has neither rhythm nor dance in +the movements of his soul and body; indeed, not even the desire for +rhythm and dance, for "music." Listen to him speaking; look at the most +beautiful Englishwoman WALKING--in no country on earth are there more +beautiful doves and swans; finally, listen to them singing! But I ask +too much... + +253. There are truths which are best recognized by mediocre minds, +because they are best adapted for them, there are truths which only +possess charms and seductive power for mediocre spirits:--one is pushed +to this probably unpleasant conclusion, now that the influence of +respectable but mediocre Englishmen--I may mention Darwin, John +Stuart Mill, and Herbert Spencer--begins to gain the ascendancy in the +middle-class region of European taste. Indeed, who could doubt that it +is a useful thing for SUCH minds to have the ascendancy for a time? It +would be an error to consider the highly developed and independently +soaring minds as specially qualified for determining and collecting many +little common facts, and deducing conclusions from them; as exceptions, +they are rather from the first in no very favourable position towards +those who are "the rules." After all, they have more to do than merely +to perceive:--in effect, they have to BE something new, they have to +SIGNIFY something new, they have to REPRESENT new values! The gulf +between knowledge and capacity is perhaps greater, and also more +mysterious, than one thinks: the capable man in the grand style, the +creator, will possibly have to be an ignorant person;--while on the +other hand, for scientific discoveries like those of Darwin, a certain +narrowness, aridity, and industrious carefulness (in short, something +English) may not be unfavourable for arriving at them.--Finally, let +it not be forgotten that the English, with their profound mediocrity, +brought about once before a general depression of European intelligence. + +What is called "modern ideas," or "the ideas of the eighteenth century," +or "French ideas"--that, consequently, against which the GERMAN mind +rose up with profound disgust--is of English origin, there is no doubt +about it. The French were only the apes and actors of these ideas, their +best soldiers, and likewise, alas! their first and profoundest VICTIMS; +for owing to the diabolical Anglomania of "modern ideas," the AME +FRANCAIS has in the end become so thin and emaciated, that at present +one recalls its sixteenth and seventeenth centuries, its profound, +passionate strength, its inventive excellency, almost with disbelief. +One must, however, maintain this verdict of historical justice in +a determined manner, and defend it against present prejudices and +appearances: the European NOBLESSE--of sentiment, taste, and manners, +taking the word in every high sense--is the work and invention of +FRANCE; the European ignobleness, the plebeianism of modern ideas--is +ENGLAND'S work and invention. + +254. Even at present France is still the seat of the most intellectual +and refined culture of Europe, it is still the high school of taste; but +one must know how to find this "France of taste." He who belongs to it +keeps himself well concealed:--they may be a small number in whom it +lives and is embodied, besides perhaps being men who do not stand upon +the strongest legs, in part fatalists, hypochondriacs, invalids, in +part persons over-indulged, over-refined, such as have the AMBITION to +conceal themselves. + +They have all something in common: they keep their ears closed in +presence of the delirious folly and noisy spouting of the democratic +BOURGEOIS. In fact, a besotted and brutalized France at present sprawls +in the foreground--it recently celebrated a veritable orgy of bad taste, +and at the same time of self-admiration, at the funeral of Victor Hugo. +There is also something else common to them: a predilection to resist +intellectual Germanizing--and a still greater inability to do so! +In this France of intellect, which is also a France of pessimism, +Schopenhauer has perhaps become more at home, and more indigenous than +he has ever been in Germany; not to speak of Heinrich Heine, who has +long ago been re-incarnated in the more refined and fastidious lyrists +of Paris; or of Hegel, who at present, in the form of Taine--the FIRST +of living historians--exercises an almost tyrannical influence. As +regards Richard Wagner, however, the more French music learns to +adapt itself to the actual needs of the AME MODERNE, the more will it +"Wagnerite"; one can safely predict that beforehand,--it is already +taking place sufficiently! There are, however, three things which the +French can still boast of with pride as their heritage and possession, +and as indelible tokens of their ancient intellectual superiority +in Europe, in spite of all voluntary or involuntary Germanizing and +vulgarizing of taste. FIRSTLY, the capacity for artistic emotion, for +devotion to "form," for which the expression, L'ART POUR L'ART, along +with numerous others, has been invented:--such capacity has not been +lacking in France for three centuries; and owing to its reverence for +the "small number," it has again and again made a sort of chamber +music of literature possible, which is sought for in vain elsewhere +in Europe.--The SECOND thing whereby the French can lay claim to +a superiority over Europe is their ancient, many-sided, MORALISTIC +culture, owing to which one finds on an average, even in the petty +ROMANCIERS of the newspapers and chance BOULEVARDIERS DE PARIS, a +psychological sensitiveness and curiosity, of which, for example, one +has no conception (to say nothing of the thing itself!) in Germany. +The Germans lack a couple of centuries of the moralistic work requisite +thereto, which, as we have said, France has not grudged: those who call +the Germans "naive" on that account give them commendation for a defect. +(As the opposite of the German inexperience and innocence IN VOLUPTATE +PSYCHOLOGICA, which is not too remotely associated with the tediousness +of German intercourse,--and as the most successful expression of +genuine French curiosity and inventive talent in this domain of delicate +thrills, Henri Beyle may be noted; that remarkable anticipatory and +forerunning man, who, with a Napoleonic TEMPO, traversed HIS Europe, +in fact, several centuries of the European soul, as a surveyor and +discoverer thereof:--it has required two generations to OVERTAKE him +one way or other, to divine long afterwards some of the riddles +that perplexed and enraptured him--this strange Epicurean and man of +interrogation, the last great psychologist of France).--There is yet +a THIRD claim to superiority: in the French character there is a +successful half-way synthesis of the North and South, which makes them +comprehend many things, and enjoins upon them other things, which an +Englishman can never comprehend. Their temperament, turned alternately +to and from the South, in which from time to time the Provencal and +Ligurian blood froths over, preserves them from the dreadful, northern +grey-in-grey, from sunless conceptual-spectrism and from poverty of +blood--our GERMAN infirmity of taste, for the excessive prevalence +of which at the present moment, blood and iron, that is to say "high +politics," has with great resolution been prescribed (according to +a dangerous healing art, which bids me wait and wait, but not yet +hope).--There is also still in France a pre-understanding and +ready welcome for those rarer and rarely gratified men, who are too +comprehensive to find satisfaction in any kind of fatherlandism, and +know how to love the South when in the North and the North when in the +South--the born Midlanders, the "good Europeans." For them BIZET +has made music, this latest genius, who has seen a new beauty and +seduction,--who has discovered a piece of the SOUTH IN MUSIC. + +255. I hold that many precautions should be taken against German music. +Suppose a person loves the South as I love it--as a great school +of recovery for the most spiritual and the most sensuous ills, as a +boundless solar profusion and effulgence which o'erspreads a sovereign +existence believing in itself--well, such a person will learn to be +somewhat on his guard against German music, because, in injuring his +taste anew, it will also injure his health anew. Such a Southerner, a +Southerner not by origin but by BELIEF, if he should dream of the future +of music, must also dream of it being freed from the influence of the +North; and must have in his ears the prelude to a deeper, mightier, and +perhaps more perverse and mysterious music, a super-German music, which +does not fade, pale, and die away, as all German music does, at the +sight of the blue, wanton sea and the Mediterranean clearness of sky--a +super-European music, which holds its own even in presence of the brown +sunsets of the desert, whose soul is akin to the palm-tree, and can be +at home and can roam with big, beautiful, lonely beasts of prey... I +could imagine a music of which the rarest charm would be that it knew +nothing more of good and evil; only that here and there perhaps some +sailor's home-sickness, some golden shadows and tender weaknesses might +sweep lightly over it; an art which, from the far distance, would see +the colours of a sinking and almost incomprehensible MORAL world fleeing +towards it, and would be hospitable enough and profound enough to +receive such belated fugitives. + +256. Owing to the morbid estrangement which the nationality-craze has +induced and still induces among the nations of Europe, owing also to the +short-sighted and hasty-handed politicians, who with the help of this +craze, are at present in power, and do not suspect to what extent the +disintegrating policy they pursue must necessarily be only an interlude +policy--owing to all this and much else that is altogether unmentionable +at present, the most unmistakable signs that EUROPE WISHES TO BE ONE, +are now overlooked, or arbitrarily and falsely misinterpreted. With all +the more profound and large-minded men of this century, the real general +tendency of the mysterious labour of their souls was to prepare the way +for that new SYNTHESIS, and tentatively to anticipate the European of +the future; only in their simulations, or in their weaker moments, in +old age perhaps, did they belong to the "fatherlands"--they only rested +from themselves when they became "patriots." I think of such men as +Napoleon, Goethe, Beethoven, Stendhal, Heinrich Heine, Schopenhauer: it +must not be taken amiss if I also count Richard Wagner among them, about +whom one must not let oneself be deceived by his own misunderstandings +(geniuses like him have seldom the right to understand themselves), +still less, of course, by the unseemly noise with which he is now +resisted and opposed in France: the fact remains, nevertheless, that +Richard Wagner and the LATER FRENCH ROMANTICISM of the forties, are +most closely and intimately related to one another. They are akin, +fundamentally akin, in all the heights and depths of their requirements; +it is Europe, the ONE Europe, whose soul presses urgently and longingly, +outwards and upwards, in their multifarious and boisterous art--whither? +into a new light? towards a new sun? But who would attempt to express +accurately what all these masters of new modes of speech could not +express distinctly? It is certain that the same storm and stress +tormented them, that they SOUGHT in the same manner, these last great +seekers! All of them steeped in literature to their eyes and ears--the +first artists of universal literary culture--for the most part even +themselves writers, poets, intermediaries and blenders of the arts and +the senses (Wagner, as musician is reckoned among painters, as poet +among musicians, as artist generally among actors); all of them fanatics +for EXPRESSION "at any cost"--I specially mention Delacroix, the nearest +related to Wagner; all of them great discoverers in the realm of the +sublime, also of the loathsome and dreadful, still greater discoverers +in effect, in display, in the art of the show-shop; all of them talented +far beyond their genius, out and out VIRTUOSI, with mysterious accesses +to all that seduces, allures, constrains, and upsets; born enemies of +logic and of the straight line, hankering after the strange, the +exotic, the monstrous, the crooked, and the self-contradictory; as men, +Tantaluses of the will, plebeian parvenus, who knew themselves to be +incapable of a noble TEMPO or of a LENTO in life and action--think +of Balzac, for instance,--unrestrained workers, almost destroying +themselves by work; antinomians and rebels in manners, ambitious and +insatiable, without equilibrium and enjoyment; all of them finally +shattering and sinking down at the Christian cross (and with right +and reason, for who of them would have been sufficiently profound and +sufficiently original for an ANTI-CHRISTIAN philosophy?);--on the +whole, a boldly daring, splendidly overbearing, high-flying, and +aloft-up-dragging class of higher men, who had first to teach their +century--and it is the century of the MASSES--the conception "higher +man."... Let the German friends of Richard Wagner advise together as to +whether there is anything purely German in the Wagnerian art, or whether +its distinction does not consist precisely in coming from SUPER-GERMAN +sources and impulses: in which connection it may not be underrated +how indispensable Paris was to the development of his type, which the +strength of his instincts made him long to visit at the most +decisive time--and how the whole style of his proceedings, of his +self-apostolate, could only perfect itself in sight of the French +socialistic original. On a more subtle comparison it will perhaps be +found, to the honour of Richard Wagner's German nature, that he has +acted in everything with more strength, daring, severity, and elevation +than a nineteenth-century Frenchman could have done--owing to the +circumstance that we Germans are as yet nearer to barbarism than the +French;--perhaps even the most remarkable creation of Richard Wagner is +not only at present, but for ever inaccessible, incomprehensible, and +inimitable to the whole latter-day Latin race: the figure of Siegfried, +that VERY FREE man, who is probably far too free, too hard, too +cheerful, too healthy, too ANTI-CATHOLIC for the taste of old and mellow +civilized nations. He may even have been a sin against Romanticism, this +anti-Latin Siegfried: well, Wagner atoned amply for this sin in his old +sad days, when--anticipating a taste which has meanwhile passed into +politics--he began, with the religious vehemence peculiar to him, to +preach, at least, THE WAY TO ROME, if not to walk therein.--That +these last words may not be misunderstood, I will call to my aid a few +powerful rhymes, which will even betray to less delicate ears what I +mean--what I mean COUNTER TO the "last Wagner" and his Parsifal music:-- + +--Is this our mode?--From German heart came this vexed ululating? From +German body, this self-lacerating? Is ours this priestly hand-dilation, +This incense-fuming exaltation? Is ours this faltering, falling, +shambling, This quite uncertain ding-dong-dangling? This sly +nun-ogling, Ave-hour-bell ringing, This wholly false enraptured +heaven-o'erspringing?--Is this our mode?--Think well!--ye still wait for +admission--For what ye hear is ROME--ROME'S FAITH BY INTUITION! + + + +CHAPTER IX. WHAT IS NOBLE? + + +257. EVERY elevation of the type "man," has hitherto been the work of an +aristocratic society and so it will always be--a society believing in +a long scale of gradations of rank and differences of worth among human +beings, and requiring slavery in some form or other. Without the PATHOS +OF DISTANCE, such as grows out of the incarnated difference of classes, +out of the constant out-looking and down-looking of the ruling caste on +subordinates and instruments, and out of their equally constant +practice of obeying and commanding, of keeping down and keeping at a +distance--that other more mysterious pathos could never have arisen, the +longing for an ever new widening of distance within the soul itself, +the formation of ever higher, rarer, further, more extended, more +comprehensive states, in short, just the elevation of the type "man," +the continued "self-surmounting of man," to use a moral formula in +a supermoral sense. To be sure, one must not resign oneself to +any humanitarian illusions about the history of the origin of an +aristocratic society (that is to say, of the preliminary condition for +the elevation of the type "man"): the truth is hard. Let us acknowledge +unprejudicedly how every higher civilization hitherto has ORIGINATED! +Men with a still natural nature, barbarians in every terrible sense of +the word, men of prey, still in possession of unbroken strength of will +and desire for power, threw themselves upon weaker, more moral, more +peaceful races (perhaps trading or cattle-rearing communities), or upon +old mellow civilizations in which the final vital force was flickering +out in brilliant fireworks of wit and depravity. At the commencement, +the noble caste was always the barbarian caste: their superiority did +not consist first of all in their physical, but in their psychical +power--they were more COMPLETE men (which at every point also implies +the same as "more complete beasts"). + +258. Corruption--as the indication that anarchy threatens to break out +among the instincts, and that the foundation of the emotions, called +"life," is convulsed--is something radically different according to +the organization in which it manifests itself. When, for instance, an +aristocracy like that of France at the beginning of the Revolution, +flung away its privileges with sublime disgust and sacrificed itself +to an excess of its moral sentiments, it was corruption:--it was really +only the closing act of the corruption which had existed for centuries, +by virtue of which that aristocracy had abdicated step by step its +lordly prerogatives and lowered itself to a FUNCTION of royalty (in +the end even to its decoration and parade-dress). The essential thing, +however, in a good and healthy aristocracy is that it should not regard +itself as a function either of the kingship or the commonwealth, but +as the SIGNIFICANCE and highest justification thereof--that it should +therefore accept with a good conscience the sacrifice of a legion +of individuals, who, FOR ITS SAKE, must be suppressed and reduced to +imperfect men, to slaves and instruments. Its fundamental belief must +be precisely that society is NOT allowed to exist for its own sake, but +only as a foundation and scaffolding, by means of which a select class +of beings may be able to elevate themselves to their higher duties, and +in general to a higher EXISTENCE: like those sun-seeking climbing plants +in Java--they are called Sipo Matador,--which encircle an oak so +long and so often with their arms, until at last, high above it, but +supported by it, they can unfold their tops in the open light, and +exhibit their happiness. + +259. To refrain mutually from injury, from violence, from exploitation, +and put one's will on a par with that of others: this may result in a +certain rough sense in good conduct among individuals when the necessary +conditions are given (namely, the actual similarity of the individuals +in amount of force and degree of worth, and their co-relation within one +organization). As soon, however, as one wished to take this principle +more generally, and if possible even as the FUNDAMENTAL PRINCIPLE OF +SOCIETY, it would immediately disclose what it really is--namely, a Will +to the DENIAL of life, a principle of dissolution and decay. Here one +must think profoundly to the very basis and resist all sentimental +weakness: life itself is ESSENTIALLY appropriation, injury, conquest +of the strange and weak, suppression, severity, obtrusion of +peculiar forms, incorporation, and at the least, putting it mildest, +exploitation;--but why should one for ever use precisely these words +on which for ages a disparaging purpose has been stamped? Even the +organization within which, as was previously supposed, the +individuals treat each other as equal--it takes place in every +healthy aristocracy--must itself, if it be a living and not a dying +organization, do all that towards other bodies, which the individuals +within it refrain from doing to each other it will have to be the +incarnated Will to Power, it will endeavour to grow, to gain ground, +attract to itself and acquire ascendancy--not owing to any morality or +immorality, but because it LIVES, and because life IS precisely Will to +Power. On no point, however, is the ordinary consciousness of Europeans +more unwilling to be corrected than on this matter, people now rave +everywhere, even under the guise of science, about coming conditions of +society in which "the exploiting character" is to be absent--that sounds +to my ears as if they promised to invent a mode of life which should +refrain from all organic functions. "Exploitation" does not belong to a +depraved, or imperfect and primitive society it belongs to the nature of +the living being as a primary organic function, it is a consequence +of the intrinsic Will to Power, which is precisely the Will to +Life--Granting that as a theory this is a novelty--as a reality it is +the FUNDAMENTAL FACT of all history let us be so far honest towards +ourselves! + +260. In a tour through the many finer and coarser moralities which have +hitherto prevailed or still prevail on the earth, I found certain traits +recurring regularly together, and connected with one another, until +finally two primary types revealed themselves to me, and a radical +distinction was brought to light. There is MASTER-MORALITY and +SLAVE-MORALITY,--I would at once add, however, that in all higher and +mixed civilizations, there are also attempts at the reconciliation of +the two moralities, but one finds still oftener the confusion and +mutual misunderstanding of them, indeed sometimes their close +juxtaposition--even in the same man, within one soul. The distinctions +of moral values have either originated in a ruling caste, pleasantly +conscious of being different from the ruled--or among the ruled class, +the slaves and dependents of all sorts. In the first case, when it is +the rulers who determine the conception "good," it is the exalted, proud +disposition which is regarded as the distinguishing feature, and that +which determines the order of rank. The noble type of man separates +from himself the beings in whom the opposite of this exalted, proud +disposition displays itself he despises them. Let it at once be noted +that in this first kind of morality the antithesis "good" and "bad" +means practically the same as "noble" and "despicable",--the antithesis +"good" and "EVIL" is of a different origin. The cowardly, the timid, the +insignificant, and those thinking merely of narrow utility are despised; +moreover, also, the distrustful, with their constrained glances, the +self-abasing, the dog-like kind of men who let themselves be abused, +the mendicant flatterers, and above all the liars:--it is a fundamental +belief of all aristocrats that the common people are untruthful. "We +truthful ones"--the nobility in ancient Greece called themselves. It is +obvious that everywhere the designations of moral value were at first +applied to MEN; and were only derivatively and at a later period applied +to ACTIONS; it is a gross mistake, therefore, when historians of morals +start with questions like, "Why have sympathetic actions been praised?" +The noble type of man regards HIMSELF as a determiner of values; he +does not require to be approved of; he passes the judgment: "What is +injurious to me is injurious in itself;" he knows that it is he himself +only who confers honour on things; he is a CREATOR OF VALUES. He +honours whatever he recognizes in himself: such morality equals +self-glorification. In the foreground there is the feeling of plenitude, +of power, which seeks to overflow, the happiness of high tension, the +consciousness of a wealth which would fain give and bestow:--the noble +man also helps the unfortunate, but not--or scarcely--out of pity, but +rather from an impulse generated by the super-abundance of power. The +noble man honours in himself the powerful one, him also who has power +over himself, who knows how to speak and how to keep silence, who +takes pleasure in subjecting himself to severity and hardness, and has +reverence for all that is severe and hard. "Wotan placed a hard heart in +my breast," says an old Scandinavian Saga: it is thus rightly expressed +from the soul of a proud Viking. Such a type of man is even proud of not +being made for sympathy; the hero of the Saga therefore adds warningly: +"He who has not a hard heart when young, will never have one." The noble +and brave who think thus are the furthest removed from the morality +which sees precisely in sympathy, or in acting for the good of others, +or in DESINTERESSEMENT, the characteristic of the moral; faith +in oneself, pride in oneself, a radical enmity and irony towards +"selflessness," belong as definitely to noble morality, as do a careless +scorn and precaution in presence of sympathy and the "warm heart."--It +is the powerful who KNOW how to honour, it is their art, their domain +for invention. The profound reverence for age and for tradition--all law +rests on this double reverence,--the belief and prejudice in favour of +ancestors and unfavourable to newcomers, is typical in the morality of +the powerful; and if, reversely, men of "modern ideas" believe almost +instinctively in "progress" and the "future," and are more and more +lacking in respect for old age, the ignoble origin of these "ideas" has +complacently betrayed itself thereby. A morality of the ruling class, +however, is more especially foreign and irritating to present-day taste +in the sternness of its principle that one has duties only to one's +equals; that one may act towards beings of a lower rank, towards all +that is foreign, just as seems good to one, or "as the heart desires," +and in any case "beyond good and evil": it is here that sympathy and +similar sentiments can have a place. The ability and obligation to +exercise prolonged gratitude and prolonged revenge--both only within the +circle of equals,--artfulness in retaliation, RAFFINEMENT of the idea +in friendship, a certain necessity to have enemies (as outlets for the +emotions of envy, quarrelsomeness, arrogance--in fact, in order to be +a good FRIEND): all these are typical characteristics of the noble +morality, which, as has been pointed out, is not the morality of "modern +ideas," and is therefore at present difficult to realize, and also to +unearth and disclose.--It is otherwise with the second type of morality, +SLAVE-MORALITY. Supposing that the abused, the oppressed, the suffering, +the unemancipated, the weary, and those uncertain of themselves should +moralize, what will be the common element in their moral estimates? +Probably a pessimistic suspicion with regard to the entire situation of +man will find expression, perhaps a condemnation of man, together with +his situation. The slave has an unfavourable eye for the virtues of the +powerful; he has a skepticism and distrust, a REFINEMENT of distrust of +everything "good" that is there honoured--he would fain persuade himself +that the very happiness there is not genuine. On the other hand, THOSE +qualities which serve to alleviate the existence of sufferers are +brought into prominence and flooded with light; it is here that +sympathy, the kind, helping hand, the warm heart, patience, diligence, +humility, and friendliness attain to honour; for here these are the most +useful qualities, and almost the only means of supporting the burden of +existence. Slave-morality is essentially the morality of utility. +Here is the seat of the origin of the famous antithesis "good" and +"evil":--power and dangerousness are assumed to reside in the evil, +a certain dreadfulness, subtlety, and strength, which do not admit of +being despised. According to slave-morality, therefore, the "evil" man +arouses fear; according to master-morality, it is precisely the "good" +man who arouses fear and seeks to arouse it, while the bad man is +regarded as the despicable being. The contrast attains its maximum when, +in accordance with the logical consequences of slave-morality, a shade +of depreciation--it may be slight and well-intentioned--at last attaches +itself to the "good" man of this morality; because, according to the +servile mode of thought, the good man must in any case be the SAFE +man: he is good-natured, easily deceived, perhaps a little stupid, un +bonhomme. Everywhere that slave-morality gains the ascendancy, language +shows a tendency to approximate the significations of the words "good" +and "stupid."--A last fundamental difference: the desire for FREEDOM, +the instinct for happiness and the refinements of the feeling of liberty +belong as necessarily to slave-morals and morality, as artifice and +enthusiasm in reverence and devotion are the regular symptoms of an +aristocratic mode of thinking and estimating.--Hence we can understand +without further detail why love AS A PASSION--it is our European +specialty--must absolutely be of noble origin; as is well known, its +invention is due to the Provencal poet-cavaliers, those brilliant, +ingenious men of the "gai saber," to whom Europe owes so much, and +almost owes itself. + +261. Vanity is one of the things which are perhaps most difficult for +a noble man to understand: he will be tempted to deny it, where another +kind of man thinks he sees it self-evidently. The problem for him is +to represent to his mind beings who seek to arouse a good opinion of +themselves which they themselves do not possess--and consequently also +do not "deserve,"--and who yet BELIEVE in this good opinion +afterwards. This seems to him on the one hand such bad taste and so +self-disrespectful, and on the other hand so grotesquely unreasonable, +that he would like to consider vanity an exception, and is doubtful +about it in most cases when it is spoken of. He will say, for +instance: "I may be mistaken about my value, and on the other hand +may nevertheless demand that my value should be acknowledged by others +precisely as I rate it:--that, however, is not vanity (but self-conceit, +or, in most cases, that which is called 'humility,' and also +'modesty')." Or he will even say: "For many reasons I can delight in +the good opinion of others, perhaps because I love and honour them, +and rejoice in all their joys, perhaps also because their good opinion +endorses and strengthens my belief in my own good opinion, perhaps +because the good opinion of others, even in cases where I do not share +it, is useful to me, or gives promise of usefulness:--all this, however, +is not vanity." The man of noble character must first bring it home +forcibly to his mind, especially with the aid of history, that, from +time immemorial, in all social strata in any way dependent, the ordinary +man WAS only that which he PASSED FOR:--not being at all accustomed to +fix values, he did not assign even to himself any other value than that +which his master assigned to him (it is the peculiar RIGHT OF MASTERS to +create values). It may be looked upon as the result of an extraordinary +atavism, that the ordinary man, even at present, is still always WAITING +for an opinion about himself, and then instinctively submitting himself +to it; yet by no means only to a "good" opinion, but also to a bad +and unjust one (think, for instance, of the greater part of the +self-appreciations and self-depreciations which believing women learn +from their confessors, and which in general the believing Christian +learns from his Church). In fact, conformably to the slow rise of the +democratic social order (and its cause, the blending of the blood +of masters and slaves), the originally noble and rare impulse of +the masters to assign a value to themselves and to "think well" of +themselves, will now be more and more encouraged and extended; but +it has at all times an older, ampler, and more radically ingrained +propensity opposed to it--and in the phenomenon of "vanity" this older +propensity overmasters the younger. The vain person rejoices over EVERY +good opinion which he hears about himself (quite apart from the point +of view of its usefulness, and equally regardless of its truth or +falsehood), just as he suffers from every bad opinion: for he subjects +himself to both, he feels himself subjected to both, by that oldest +instinct of subjection which breaks forth in him.--It is "the slave" +in the vain man's blood, the remains of the slave's craftiness--and how +much of the "slave" is still left in woman, for instance!--which +seeks to SEDUCE to good opinions of itself; it is the slave, too, who +immediately afterwards falls prostrate himself before these opinions, as +though he had not called them forth.--And to repeat it again: vanity is +an atavism. + +262. A SPECIES originates, and a type becomes established and strong in +the long struggle with essentially constant UNFAVOURABLE conditions. On +the other hand, it is known by the experience of breeders that species +which receive super-abundant nourishment, and in general a surplus of +protection and care, immediately tend in the most marked way to develop +variations, and are fertile in prodigies and monstrosities (also in +monstrous vices). Now look at an aristocratic commonwealth, say +an ancient Greek polis, or Venice, as a voluntary or involuntary +contrivance for the purpose of REARING human beings; there are there men +beside one another, thrown upon their own resources, who want to make +their species prevail, chiefly because they MUST prevail, or else +run the terrible danger of being exterminated. The favour, the +super-abundance, the protection are there lacking under which variations +are fostered; the species needs itself as species, as something which, +precisely by virtue of its hardness, its uniformity, and simplicity of +structure, can in general prevail and make itself permanent in +constant struggle with its neighbours, or with rebellious or +rebellion-threatening vassals. The most varied experience teaches it +what are the qualities to which it principally owes the fact that +it still exists, in spite of all Gods and men, and has hitherto been +victorious: these qualities it calls virtues, and these virtues alone +it develops to maturity. It does so with severity, indeed it desires +severity; every aristocratic morality is intolerant in the education +of youth, in the control of women, in the marriage customs, in the +relations of old and young, in the penal laws (which have an eye only +for the degenerating): it counts intolerance itself among the virtues, +under the name of "justice." A type with few, but very marked features, +a species of severe, warlike, wisely silent, reserved, and reticent +men (and as such, with the most delicate sensibility for the charm and +nuances of society) is thus established, unaffected by the vicissitudes +of generations; the constant struggle with uniform UNFAVOURABLE +conditions is, as already remarked, the cause of a type becoming +stable and hard. Finally, however, a happy state of things results, the +enormous tension is relaxed; there are perhaps no more enemies among the +neighbouring peoples, and the means of life, even of the enjoyment +of life, are present in superabundance. With one stroke the bond and +constraint of the old discipline severs: it is no longer regarded as +necessary, as a condition of existence--if it would continue, it can +only do so as a form of LUXURY, as an archaizing TASTE. Variations, +whether they be deviations (into the higher, finer, and rarer), or +deteriorations and monstrosities, appear suddenly on the scene in the +greatest exuberance and splendour; the individual dares to be individual +and detach himself. At this turning-point of history there manifest +themselves, side by side, and often mixed and entangled together, a +magnificent, manifold, virgin-forest-like up-growth and up-striving, a +kind of TROPICAL TEMPO in the rivalry of growth, and an extraordinary +decay and self-destruction, owing to the savagely opposing and seemingly +exploding egoisms, which strive with one another "for sun and light," +and can no longer assign any limit, restraint, or forbearance for +themselves by means of the hitherto existing morality. It was this +morality itself which piled up the strength so enormously, which bent +the bow in so threatening a manner:--it is now "out of date," it is +getting "out of date." The dangerous and disquieting point has been +reached when the greater, more manifold, more comprehensive life IS +LIVED BEYOND the old morality; the "individual" stands out, and is +obliged to have recourse to his own law-giving, his own arts and +artifices for self-preservation, self-elevation, and self-deliverance. +Nothing but new "Whys," nothing but new "Hows," no common formulas any +longer, misunderstanding and disregard in league with each other, decay, +deterioration, and the loftiest desires frightfully entangled, the +genius of the race overflowing from all the cornucopias of good and bad, +a portentous simultaneousness of Spring and Autumn, full of new charms +and mysteries peculiar to the fresh, still inexhausted, still unwearied +corruption. Danger is again present, the mother of morality, great +danger; this time shifted into the individual, into the neighbour and +friend, into the street, into their own child, into their own heart, +into all the most personal and secret recesses of their desires and +volitions. What will the moral philosophers who appear at this time have +to preach? They discover, these sharp onlookers and loafers, that the +end is quickly approaching, that everything around them decays and +produces decay, that nothing will endure until the day after tomorrow, +except one species of man, the incurably MEDIOCRE. The mediocre alone +have a prospect of continuing and propagating themselves--they will +be the men of the future, the sole survivors; "be like them! become +mediocre!" is now the only morality which has still a significance, +which still obtains a hearing.--But it is difficult to preach this +morality of mediocrity! it can never avow what it is and what it +desires! it has to talk of moderation and dignity and duty and brotherly +love--it will have difficulty IN CONCEALING ITS IRONY! + +263. There is an INSTINCT FOR RANK, which more than anything else is +already the sign of a HIGH rank; there is a DELIGHT in the NUANCES +of reverence which leads one to infer noble origin and habits. The +refinement, goodness, and loftiness of a soul are put to a perilous test +when something passes by that is of the highest rank, but is not +yet protected by the awe of authority from obtrusive touches and +incivilities: something that goes its way like a living touchstone, +undistinguished, undiscovered, and tentative, perhaps voluntarily veiled +and disguised. He whose task and practice it is to investigate souls, +will avail himself of many varieties of this very art to determine the +ultimate value of a soul, the unalterable, innate order of rank to which +it belongs: he will test it by its INSTINCT FOR REVERENCE. DIFFERENCE +ENGENDRE HAINE: the vulgarity of many a nature spurts up suddenly like +dirty water, when any holy vessel, any jewel from closed shrines, any +book bearing the marks of great destiny, is brought before it; while +on the other hand, there is an involuntary silence, a hesitation of the +eye, a cessation of all gestures, by which it is indicated that a soul +FEELS the nearness of what is worthiest of respect. The way in which, on +the whole, the reverence for the BIBLE has hitherto been maintained +in Europe, is perhaps the best example of discipline and refinement of +manners which Europe owes to Christianity: books of such profoundness +and supreme significance require for their protection an external +tyranny of authority, in order to acquire the PERIOD of thousands of +years which is necessary to exhaust and unriddle them. Much has been +achieved when the sentiment has been at last instilled into the masses +(the shallow-pates and the boobies of every kind) that they are not +allowed to touch everything, that there are holy experiences before +which they must take off their shoes and keep away the unclean hand--it +is almost their highest advance towards humanity. On the contrary, in +the so-called cultured classes, the believers in "modern ideas," nothing +is perhaps so repulsive as their lack of shame, the easy insolence of +eye and hand with which they touch, taste, and finger everything; and it +is possible that even yet there is more RELATIVE nobility of taste, and +more tact for reverence among the people, among the lower classes of +the people, especially among peasants, than among the newspaper-reading +DEMIMONDE of intellect, the cultured class. + +264. It cannot be effaced from a man's soul what his ancestors have +preferably and most constantly done: whether they were perhaps diligent +economizers attached to a desk and a cash-box, modest and citizen-like +in their desires, modest also in their virtues; or whether they were +accustomed to commanding from morning till night, fond of rude pleasures +and probably of still ruder duties and responsibilities; or whether, +finally, at one time or another, they have sacrificed old privileges of +birth and possession, in order to live wholly for their faith--for their +"God,"--as men of an inexorable and sensitive conscience, which blushes +at every compromise. It is quite impossible for a man NOT to have +the qualities and predilections of his parents and ancestors in his +constitution, whatever appearances may suggest to the contrary. This is +the problem of race. Granted that one knows something of the parents, +it is admissible to draw a conclusion about the child: any kind +of offensive incontinence, any kind of sordid envy, or of clumsy +self-vaunting--the three things which together have constituted the +genuine plebeian type in all times--such must pass over to the child, as +surely as bad blood; and with the help of the best education and culture +one will only succeed in DECEIVING with regard to such heredity.--And +what else does education and culture try to do nowadays! In our very +democratic, or rather, very plebeian age, "education" and "culture" MUST +be essentially the art of deceiving--deceiving with regard to origin, +with regard to the inherited plebeianism in body and soul. An educator +who nowadays preached truthfulness above everything else, and called out +constantly to his pupils: "Be true! Be natural! Show yourselves as you +are!"--even such a virtuous and sincere ass would learn in a short time +to have recourse to the FURCA of Horace, NATURAM EXPELLERE: with what +results? "Plebeianism" USQUE RECURRET. [FOOTNOTE: Horace's "Epistles," +I. x. 24.] + +265. At the risk of displeasing innocent ears, I submit that egoism +belongs to the essence of a noble soul, I mean the unalterable belief +that to a being such as "we," other beings must naturally be in +subjection, and have to sacrifice themselves. The noble soul accepts the +fact of his egoism without question, and also without consciousness of +harshness, constraint, or arbitrariness therein, but rather as something +that may have its basis in the primary law of things:--if he sought a +designation for it he would say: "It is justice itself." He acknowledges +under certain circumstances, which made him hesitate at first, that +there are other equally privileged ones; as soon as he has settled this +question of rank, he moves among those equals and equally privileged +ones with the same assurance, as regards modesty and delicate respect, +which he enjoys in intercourse with himself--in accordance with an +innate heavenly mechanism which all the stars understand. It is an +ADDITIONAL instance of his egoism, this artfulness and self-limitation +in intercourse with his equals--every star is a similar egoist; he +honours HIMSELF in them, and in the rights which he concedes to them, he +has no doubt that the exchange of honours and rights, as the ESSENCE of +all intercourse, belongs also to the natural condition of things. The +noble soul gives as he takes, prompted by the passionate and sensitive +instinct of requital, which is at the root of his nature. The notion of +"favour" has, INTER PARES, neither significance nor good repute; there +may be a sublime way of letting gifts as it were light upon one from +above, and of drinking them thirstily like dew-drops; but for those +arts and displays the noble soul has no aptitude. His egoism hinders him +here: in general, he looks "aloft" unwillingly--he looks either FORWARD, +horizontally and deliberately, or downwards--HE KNOWS THAT HE IS ON A +HEIGHT. + +266. "One can only truly esteem him who does not LOOK OUT FOR +himself."--Goethe to Rath Schlosser. + +267. The Chinese have a proverb which mothers even teach their children: +"SIAO-SIN" ("MAKE THY HEART SMALL"). This is the essentially fundamental +tendency in latter-day civilizations. I have no doubt that an ancient +Greek, also, would first of all remark the self-dwarfing in us Europeans +of today--in this respect alone we should immediately be "distasteful" +to him. + +268. What, after all, is ignobleness?--Words are vocal symbols for +ideas; ideas, however, are more or less definite mental symbols +for frequently returning and concurring sensations, for groups of +sensations. It is not sufficient to use the same words in order to +understand one another: we must also employ the same words for the same +kind of internal experiences, we must in the end have experiences IN +COMMON. On this account the people of one nation understand one another +better than those belonging to different nations, even when they use +the same language; or rather, when people have lived long together under +similar conditions (of climate, soil, danger, requirement, toil) there +ORIGINATES therefrom an entity that "understands itself"--namely, a +nation. In all souls a like number of frequently recurring experiences +have gained the upper hand over those occurring more rarely: about +these matters people understand one another rapidly and always more +rapidly--the history of language is the history of a process of +abbreviation; on the basis of this quick comprehension people always +unite closer and closer. The greater the danger, the greater is the +need of agreeing quickly and readily about what is necessary; not to +misunderstand one another in danger--that is what cannot at all be +dispensed with in intercourse. Also in all loves and friendships one has +the experience that nothing of the kind continues when the discovery +has been made that in using the same words, one of the two parties has +feelings, thoughts, intuitions, wishes, or fears different from those of +the other. (The fear of the "eternal misunderstanding": that is the good +genius which so often keeps persons of different sexes from too +hasty attachments, to which sense and heart prompt them--and NOT some +Schopenhauerian "genius of the species"!) Whichever groups of sensations +within a soul awaken most readily, begin to speak, and give the word of +command--these decide as to the general order of rank of its values, and +determine ultimately its list of desirable things. A man's estimates of +value betray something of the STRUCTURE of his soul, and wherein it +sees its conditions of life, its intrinsic needs. Supposing now that +necessity has from all time drawn together only such men as could +express similar requirements and similar experiences by similar symbols, +it results on the whole that the easy COMMUNICABILITY of need, +which implies ultimately the undergoing only of average and COMMON +experiences, must have been the most potent of all the forces which +have hitherto operated upon mankind. The more similar, the more ordinary +people, have always had and are still having the advantage; the more +select, more refined, more unique, and difficultly comprehensible, are +liable to stand alone; they succumb to accidents in their isolation, and +seldom propagate themselves. One must appeal to immense opposing forces, +in order to thwart this natural, all-too-natural PROGRESSUS IN SIMILE, +the evolution of man to the similar, the ordinary, the average, the +gregarious--to the IGNOBLE--! + +269. The more a psychologist--a born, an unavoidable psychologist +and soul-diviner--turns his attention to the more select cases and +individuals, the greater is his danger of being suffocated by sympathy: +he NEEDS sternness and cheerfulness more than any other man. For +the corruption, the ruination of higher men, of the more unusually +constituted souls, is in fact, the rule: it is dreadful to have such a +rule always before one's eyes. The manifold torment of the psychologist +who has discovered this ruination, who discovers once, and then +discovers ALMOST repeatedly throughout all history, this universal +inner "desperateness" of higher men, this eternal "too late!" in every +sense--may perhaps one day be the cause of his turning with +bitterness against his own lot, and of his making an attempt at +self-destruction--of his "going to ruin" himself. One may perceive +in almost every psychologist a tell-tale inclination for delightful +intercourse with commonplace and well-ordered men; the fact is thereby +disclosed that he always requires healing, that he needs a sort +of flight and forgetfulness, away from what his insight and +incisiveness--from what his "business"--has laid upon his conscience. +The fear of his memory is peculiar to him. He is easily silenced by the +judgment of others; he hears with unmoved countenance how people honour, +admire, love, and glorify, where he has PERCEIVED--or he even conceals +his silence by expressly assenting to some plausible opinion. Perhaps +the paradox of his situation becomes so dreadful that, precisely +where he has learnt GREAT SYMPATHY, together with great CONTEMPT, the +multitude, the educated, and the visionaries, have on their part learnt +great reverence--reverence for "great men" and marvelous animals, for +the sake of whom one blesses and honours the fatherland, the earth, the +dignity of mankind, and one's own self, to whom one points the young, +and in view of whom one educates them. And who knows but in all great +instances hitherto just the same happened: that the multitude worshipped +a God, and that the "God" was only a poor sacrificial animal! SUCCESS +has always been the greatest liar--and the "work" itself is a success; +the great statesman, the conqueror, the discoverer, are disguised in +their creations until they are unrecognizable; the "work" of the artist, +of the philosopher, only invents him who has created it, is REPUTED +to have created it; the "great men," as they are reverenced, are poor +little fictions composed afterwards; in the world of historical values +spurious coinage PREVAILS. Those great poets, for example, such as +Byron, Musset, Poe, Leopardi, Kleist, Gogol (I do not venture to mention +much greater names, but I have them in my mind), as they now appear, and +were perhaps obliged to be: men of the moment, enthusiastic, sensuous, +and childish, light-minded and impulsive in their trust and distrust; +with souls in which usually some flaw has to be concealed; often taking +revenge with their works for an internal defilement, often seeking +forgetfulness in their soaring from a too true memory, often lost in +the mud and almost in love with it, until they become like the +Will-o'-the-Wisps around the swamps, and PRETEND TO BE stars--the people +then call them idealists,--often struggling with protracted disgust, +with an ever-reappearing phantom of disbelief, which makes them cold, +and obliges them to languish for GLORIA and devour "faith as it is" +out of the hands of intoxicated adulators:--what a TORMENT these great +artists are and the so-called higher men in general, to him who has once +found them out! It is thus conceivable that it is just from woman--who +is clairvoyant in the world of suffering, and also unfortunately eager +to help and save to an extent far beyond her powers--that THEY have +learnt so readily those outbreaks of boundless devoted SYMPATHY, which +the multitude, above all the reverent multitude, do not understand, +and overwhelm with prying and self-gratifying interpretations. This +sympathizing invariably deceives itself as to its power; woman would +like to believe that love can do EVERYTHING--it is the SUPERSTITION +peculiar to her. Alas, he who knows the heart finds out how poor, +helpless, pretentious, and blundering even the best and deepest love +is--he finds that it rather DESTROYS than saves!--It is possible that +under the holy fable and travesty of the life of Jesus there is hidden +one of the most painful cases of the martyrdom of KNOWLEDGE ABOUT LOVE: +the martyrdom of the most innocent and most craving heart, that +never had enough of any human love, that DEMANDED love, that demanded +inexorably and frantically to be loved and nothing else, with terrible +outbursts against those who refused him their love; the story of a poor +soul insatiated and insatiable in love, that had to invent hell to send +thither those who WOULD NOT love him--and that at last, enlightened +about human love, had to invent a God who is entire love, entire +CAPACITY for love--who takes pity on human love, because it is so +paltry, so ignorant! He who has such sentiments, he who has such +KNOWLEDGE about love--SEEKS for death!--But why should one deal with +such painful matters? Provided, of course, that one is not obliged to do +so. + +270. The intellectual haughtiness and loathing of every man who has +suffered deeply--it almost determines the order of rank HOW deeply men +can suffer--the chilling certainty, with which he is thoroughly imbued +and coloured, that by virtue of his suffering he KNOWS MORE than the +shrewdest and wisest can ever know, that he has been familiar with, +and "at home" in, many distant, dreadful worlds of which "YOU know +nothing"!--this silent intellectual haughtiness of the sufferer, this +pride of the elect of knowledge, of the "initiated," of the almost +sacrificed, finds all forms of disguise necessary to protect itself from +contact with officious and sympathizing hands, and in general from all +that is not its equal in suffering. Profound suffering makes noble: +it separates.--One of the most refined forms of disguise is Epicurism, +along with a certain ostentatious boldness of taste, which takes +suffering lightly, and puts itself on the defensive against all that +is sorrowful and profound. They are "gay men" who make use of gaiety, +because they are misunderstood on account of it--they WISH to be +misunderstood. There are "scientific minds" who make use of science, +because it gives a gay appearance, and because scientificness leads to +the conclusion that a person is superficial--they WISH to mislead to a +false conclusion. There are free insolent minds which would fain conceal +and deny that they are broken, proud, incurable hearts (the cynicism of +Hamlet--the case of Galiani); and occasionally folly itself is the mask +of an unfortunate OVER-ASSURED knowledge.--From which it follows that it +is the part of a more refined humanity to have reverence "for the mask," +and not to make use of psychology and curiosity in the wrong place. + +271. That which separates two men most profoundly is a different sense +and grade of purity. What does it matter about all their honesty and +reciprocal usefulness, what does it matter about all their mutual +good-will: the fact still remains--they "cannot smell each other!" The +highest instinct for purity places him who is affected with it in the +most extraordinary and dangerous isolation, as a saint: for it is just +holiness--the highest spiritualization of the instinct in question. Any +kind of cognizance of an indescribable excess in the joy of the bath, +any kind of ardour or thirst which perpetually impels the soul out +of night into the morning, and out of gloom, out of "affliction" into +clearness, brightness, depth, and refinement:--just as much as such a +tendency DISTINGUISHES--it is a noble tendency--it also SEPARATES.--The +pity of the saint is pity for the FILTH of the human, all-too-human. +And there are grades and heights where pity itself is regarded by him as +impurity, as filth. + +272. Signs of nobility: never to think of lowering our duties to the +rank of duties for everybody; to be unwilling to renounce or to share +our responsibilities; to count our prerogatives, and the exercise of +them, among our DUTIES. + +273. A man who strives after great things, looks upon every one whom +he encounters on his way either as a means of advance, or a delay and +hindrance--or as a temporary resting-place. His peculiar lofty BOUNTY +to his fellow-men is only possible when he attains his elevation and +dominates. Impatience, and the consciousness of being always condemned +to comedy up to that time--for even strife is a comedy, and conceals the +end, as every means does--spoil all intercourse for him; this kind of +man is acquainted with solitude, and what is most poisonous in it. + +274. THE PROBLEM OF THOSE WHO WAIT.--Happy chances are necessary, and +many incalculable elements, in order that a higher man in whom the +solution of a problem is dormant, may yet take action, or "break forth," +as one might say--at the right moment. On an average it DOES NOT happen; +and in all corners of the earth there are waiting ones sitting who +hardly know to what extent they are waiting, and still less that they +wait in vain. Occasionally, too, the waking call comes too late--the +chance which gives "permission" to take action--when their best youth, +and strength for action have been used up in sitting still; and how many +a one, just as he "sprang up," has found with horror that his limbs are +benumbed and his spirits are now too heavy! "It is too late," he has +said to himself--and has become self-distrustful and henceforth for ever +useless.--In the domain of genius, may not the "Raphael without +hands" (taking the expression in its widest sense) perhaps not be the +exception, but the rule?--Perhaps genius is by no means so rare: but +rather the five hundred HANDS which it requires in order to tyrannize +over the [GREEK INSERTED HERE], "the right time"--in order to take +chance by the forelock! + +275. He who does not WISH to see the height of a man, looks all the +more sharply at what is low in him, and in the foreground--and thereby +betrays himself. + +276. In all kinds of injury and loss the lower and coarser soul is +better off than the nobler soul: the dangers of the latter must be +greater, the probability that it will come to grief and perish is in +fact immense, considering the multiplicity of the conditions of its +existence.--In a lizard a finger grows again which has been lost; not so +in man.-- + +277. It is too bad! Always the old story! When a man has finished +building his house, he finds that he has learnt unawares something +which he OUGHT absolutely to have known before he--began to build. The +eternal, fatal "Too late!" The melancholia of everything COMPLETED--! + +278.--Wanderer, who art thou? I see thee follow thy path without scorn, +without love, with unfathomable eyes, wet and sad as a plummet which has +returned to the light insatiated out of every depth--what did it seek +down there?--with a bosom that never sighs, with lips that conceal their +loathing, with a hand which only slowly grasps: who art thou? what +hast thou done? Rest thee here: this place has hospitality for every +one--refresh thyself! And whoever thou art, what is it that now pleases +thee? What will serve to refresh thee? Only name it, whatever I have +I offer thee! "To refresh me? To refresh me? Oh, thou prying one, +what sayest thou! But give me, I pray thee---" What? what? Speak out! +"Another mask! A second mask!" + +279. Men of profound sadness betray themselves when they are happy: they +have a mode of seizing upon happiness as though they would choke and +strangle it, out of jealousy--ah, they know only too well that it will +flee from them! + +280. "Bad! Bad! What? Does he not--go back?" Yes! But you misunderstand +him when you complain about it. He goes back like every one who is about +to make a great spring. + +281.--"Will people believe it of me? But I insist that they believe it +of me: I have always thought very unsatisfactorily of myself and about +myself, only in very rare cases, only compulsorily, always without +delight in 'the subject,' ready to digress from 'myself,' and always +without faith in the result, owing to an unconquerable distrust of the +POSSIBILITY of self-knowledge, which has led me so far as to feel a +CONTRADICTIO IN ADJECTO even in the idea of 'direct knowledge' which +theorists allow themselves:--this matter of fact is almost the most +certain thing I know about myself. There must be a sort of repugnance +in me to BELIEVE anything definite about myself.--Is there perhaps +some enigma therein? Probably; but fortunately nothing for my own +teeth.--Perhaps it betrays the species to which I belong?--but not to +myself, as is sufficiently agreeable to me." + +282.--"But what has happened to you?"--"I do not know," he said, +hesitatingly; "perhaps the Harpies have flown over my table."--It +sometimes happens nowadays that a gentle, sober, retiring man becomes +suddenly mad, breaks the plates, upsets the table, shrieks, raves, +and shocks everybody--and finally withdraws, ashamed, and raging at +himself--whither? for what purpose? To famish apart? To suffocate with +his memories?--To him who has the desires of a lofty and dainty soul, +and only seldom finds his table laid and his food prepared, the danger +will always be great--nowadays, however, it is extraordinarily so. +Thrown into the midst of a noisy and plebeian age, with which he does +not like to eat out of the same dish, he may readily perish of hunger +and thirst--or, should he nevertheless finally "fall to," of sudden +nausea.--We have probably all sat at tables to which we did not belong; +and precisely the most spiritual of us, who are most difficult to +nourish, know the dangerous DYSPEPSIA which originates from a sudden +insight and disillusionment about our food and our messmates--the +AFTER-DINNER NAUSEA. + +283. If one wishes to praise at all, it is a delicate and at the +same time a noble self-control, to praise only where one DOES NOT +agree--otherwise in fact one would praise oneself, which is contrary +to good taste:--a self-control, to be sure, which offers excellent +opportunity and provocation to constant MISUNDERSTANDING. To be able to +allow oneself this veritable luxury of taste and morality, one must +not live among intellectual imbeciles, but rather among men whose +misunderstandings and mistakes amuse by their refinement--or one will +have to pay dearly for it!--"He praises me, THEREFORE he acknowledges me +to be right"--this asinine method of inference spoils half of the life +of us recluses, for it brings the asses into our neighbourhood and +friendship. + +284. To live in a vast and proud tranquility; always beyond... To have, +or not to have, one's emotions, one's For and Against, according to +choice; to lower oneself to them for hours; to SEAT oneself on them as +upon horses, and often as upon asses:--for one must know how to make +use of their stupidity as well as of their fire. To conserve one's +three hundred foregrounds; also one's black spectacles: for there are +circumstances when nobody must look into our eyes, still less into our +"motives." And to choose for company that roguish and cheerful vice, +politeness. And to remain master of one's four virtues, courage, +insight, sympathy, and solitude. For solitude is a virtue with us, as +a sublime bent and bias to purity, which divines that in the contact of +man and man--"in society"--it must be unavoidably impure. All society +makes one somehow, somewhere, or sometime--"commonplace." + +285. The greatest events and thoughts--the greatest thoughts, however, +are the greatest events--are longest in being comprehended: the +generations which are contemporary with them do not EXPERIENCE such +events--they live past them. Something happens there as in the realm of +stars. The light of the furthest stars is longest in reaching man; and +before it has arrived man DENIES--that there are stars there. "How +many centuries does a mind require to be understood?"--that is also a +standard, one also makes a gradation of rank and an etiquette therewith, +such as is necessary for mind and for star. + +286. "Here is the prospect free, the mind exalted." [FOOTNOTE: Goethe's +"Faust," Part II, Act V. The words of Dr. Marianus.]--But there is a +reverse kind of man, who is also upon a height, and has also a free +prospect--but looks DOWNWARDS. + +287. What is noble? What does the word "noble" still mean for us +nowadays? How does the noble man betray himself, how is he recognized +under this heavy overcast sky of the commencing plebeianism, by which +everything is rendered opaque and leaden?--It is not his actions which +establish his claim--actions are always ambiguous, always inscrutable; +neither is it his "works." One finds nowadays among artists and scholars +plenty of those who betray by their works that a profound longing for +nobleness impels them; but this very NEED of nobleness is radically +different from the needs of the noble soul itself, and is in fact the +eloquent and dangerous sign of the lack thereof. It is not the works, +but the BELIEF which is here decisive and determines the order of +rank--to employ once more an old religious formula with a new and deeper +meaning--it is some fundamental certainty which a noble soul has about +itself, something which is not to be sought, is not to be found, and +perhaps, also, is not to be lost.--THE NOBLE SOUL HAS REVERENCE FOR +ITSELF.-- + +288. There are men who are unavoidably intellectual, let them turn +and twist themselves as they will, and hold their hands before their +treacherous eyes--as though the hand were not a betrayer; it always +comes out at last that they have something which they hide--namely, +intellect. One of the subtlest means of deceiving, at least as long as +possible, and of successfully representing oneself to be stupider +than one really is--which in everyday life is often as desirable as +an umbrella,--is called ENTHUSIASM, including what belongs to it, for +instance, virtue. For as Galiani said, who was obliged to know it: VERTU +EST ENTHOUSIASME. + +289. In the writings of a recluse one always hears something of the echo +of the wilderness, something of the murmuring tones and timid vigilance +of solitude; in his strongest words, even in his cry itself, there +sounds a new and more dangerous kind of silence, of concealment. He who +has sat day and night, from year's end to year's end, alone with his +soul in familiar discord and discourse, he who has become a cave-bear, +or a treasure-seeker, or a treasure-guardian and dragon in his cave--it +may be a labyrinth, but can also be a gold-mine--his ideas themselves +eventually acquire a twilight-colour of their own, and an odour, as much +of the depth as of the mould, something uncommunicative and repulsive, +which blows chilly upon every passer-by. The recluse does not believe +that a philosopher--supposing that a philosopher has always in the first +place been a recluse--ever expressed his actual and ultimate opinions in +books: are not books written precisely to hide what is in us?--indeed, +he will doubt whether a philosopher CAN have "ultimate and actual" +opinions at all; whether behind every cave in him there is not, and must +necessarily be, a still deeper cave: an ampler, stranger, richer +world beyond the surface, an abyss behind every bottom, beneath every +"foundation." Every philosophy is a foreground philosophy--this is a +recluse's verdict: "There is something arbitrary in the fact that the +PHILOSOPHER came to a stand here, took a retrospect, and looked around; +that he HERE laid his spade aside and did not dig any deeper--there +is also something suspicious in it." Every philosophy also CONCEALS a +philosophy; every opinion is also a LURKING-PLACE, every word is also a +MASK. + +290. Every deep thinker is more afraid of being understood than of being +misunderstood. The latter perhaps wounds his vanity; but the former +wounds his heart, his sympathy, which always says: "Ah, why would you +also have as hard a time of it as I have?" + +291. Man, a COMPLEX, mendacious, artful, and inscrutable animal, uncanny +to the other animals by his artifice and sagacity, rather than by his +strength, has invented the good conscience in order finally to enjoy his +soul as something SIMPLE; and the whole of morality is a long, audacious +falsification, by virtue of which generally enjoyment at the sight of +the soul becomes possible. From this point of view there is perhaps much +more in the conception of "art" than is generally believed. + +292. A philosopher: that is a man who constantly experiences, sees, +hears, suspects, hopes, and dreams extraordinary things; who is struck +by his own thoughts as if they came from the outside, from above and +below, as a species of events and lightning-flashes PECULIAR TO HIM; who +is perhaps himself a storm pregnant with new lightnings; a portentous +man, around whom there is always rumbling and mumbling and gaping and +something uncanny going on. A philosopher: alas, a being who often +runs away from himself, is often afraid of himself--but whose curiosity +always makes him "come to himself" again. + +293. A man who says: "I like that, I take it for my own, and mean to +guard and protect it from every one"; a man who can conduct a case, +carry out a resolution, remain true to an opinion, keep hold of a woman, +punish and overthrow insolence; a man who has his indignation and his +sword, and to whom the weak, the suffering, the oppressed, and even the +animals willingly submit and naturally belong; in short, a man who is a +MASTER by nature--when such a man has sympathy, well! THAT sympathy has +value! But of what account is the sympathy of those who suffer! Or of +those even who preach sympathy! There is nowadays, throughout almost the +whole of Europe, a sickly irritability and sensitiveness towards pain, +and also a repulsive irrestrainableness in complaining, an effeminizing, +which, with the aid of religion and philosophical nonsense, seeks +to deck itself out as something superior--there is a regular cult of +suffering. The UNMANLINESS of that which is called "sympathy" by such +groups of visionaries, is always, I believe, the first thing that +strikes the eye.--One must resolutely and radically taboo this latest +form of bad taste; and finally I wish people to put the good amulet, +"GAI SABER" ("gay science," in ordinary language), on heart and neck, as +a protection against it. + +294. THE OLYMPIAN VICE.--Despite the philosopher who, as a genuine +Englishman, tried to bring laughter into bad repute in all thinking +minds--"Laughing is a bad infirmity of human nature, which every +thinking mind will strive to overcome" (Hobbes),--I would even +allow myself to rank philosophers according to the quality of their +laughing--up to those who are capable of GOLDEN laughter. And supposing +that Gods also philosophize, which I am strongly inclined to believe, +owing to many reasons--I have no doubt that they also know how to laugh +thereby in an overman-like and new fashion--and at the expense of all +serious things! Gods are fond of ridicule: it seems that they cannot +refrain from laughter even in holy matters. + +295. The genius of the heart, as that great mysterious one possesses +it, the tempter-god and born rat-catcher of consciences, whose voice can +descend into the nether-world of every soul, who neither speaks a word +nor casts a glance in which there may not be some motive or touch +of allurement, to whose perfection it pertains that he knows how to +appear,--not as he is, but in a guise which acts as an ADDITIONAL +constraint on his followers to press ever closer to him, to follow him +more cordially and thoroughly;--the genius of the heart, which imposes +silence and attention on everything loud and self-conceited, which +smoothes rough souls and makes them taste a new longing--to lie placid +as a mirror, that the deep heavens may be reflected in them;--the genius +of the heart, which teaches the clumsy and too hasty hand to hesitate, +and to grasp more delicately; which scents the hidden and forgotten +treasure, the drop of goodness and sweet spirituality under thick dark +ice, and is a divining-rod for every grain of gold, long buried and +imprisoned in mud and sand; the genius of the heart, from contact with +which every one goes away richer; not favoured or surprised, not as +though gratified and oppressed by the good things of others; but richer +in himself, newer than before, broken up, blown upon, and sounded by a +thawing wind; more uncertain, perhaps, more delicate, more fragile, more +bruised, but full of hopes which as yet lack names, full of a new will +and current, full of a new ill-will and counter-current... but what am I +doing, my friends? Of whom am I talking to you? Have I forgotten myself +so far that I have not even told you his name? Unless it be that you +have already divined of your own accord who this questionable God +and spirit is, that wishes to be PRAISED in such a manner? For, as it +happens to every one who from childhood onward has always been on his +legs, and in foreign lands, I have also encountered on my path many +strange and dangerous spirits; above all, however, and again and again, +the one of whom I have just spoken: in fact, no less a personage than +the God DIONYSUS, the great equivocator and tempter, to whom, as you +know, I once offered in all secrecy and reverence my first-fruits--the +last, as it seems to me, who has offered a SACRIFICE to him, for I +have found no one who could understand what I was then doing. In +the meantime, however, I have learned much, far too much, about the +philosophy of this God, and, as I said, from mouth to mouth--I, the last +disciple and initiate of the God Dionysus: and perhaps I might at last +begin to give you, my friends, as far as I am allowed, a little taste of +this philosophy? In a hushed voice, as is but seemly: for it has to do +with much that is secret, new, strange, wonderful, and uncanny. The +very fact that Dionysus is a philosopher, and that therefore Gods also +philosophize, seems to me a novelty which is not unensnaring, and might +perhaps arouse suspicion precisely among philosophers;--among you, my +friends, there is less to be said against it, except that it comes too +late and not at the right time; for, as it has been disclosed to me, you +are loth nowadays to believe in God and gods. It may happen, too, that +in the frankness of my story I must go further than is agreeable to the +strict usages of your ears? Certainly the God in question went further, +very much further, in such dialogues, and was always many paces ahead of +me... Indeed, if it were allowed, I should have to give him, according +to human usage, fine ceremonious tides of lustre and merit, I should +have to extol his courage as investigator and discoverer, his fearless +honesty, truthfulness, and love of wisdom. But such a God does not know +what to do with all that respectable trumpery and pomp. "Keep that," he +would say, "for thyself and those like thee, and whoever else require +it! I--have no reason to cover my nakedness!" One suspects that this +kind of divinity and philosopher perhaps lacks shame?--He once said: +"Under certain circumstances I love mankind"--and referred thereby to +Ariadne, who was present; "in my opinion man is an agreeable, brave, +inventive animal, that has not his equal upon earth, he makes his way +even through all labyrinths. I like man, and often think how I can +still further advance him, and make him stronger, more evil, and more +profound."--"Stronger, more evil, and more profound?" I asked in horror. +"Yes," he said again, "stronger, more evil, and more profound; also more +beautiful"--and thereby the tempter-god smiled with his halcyon smile, +as though he had just paid some charming compliment. One here sees at +once that it is not only shame that this divinity lacks;--and in general +there are good grounds for supposing that in some things the Gods could +all of them come to us men for instruction. We men are--more human.-- + +296. Alas! what are you, after all, my written and painted thoughts! Not +long ago you were so variegated, young and malicious, so full of thorns +and secret spices, that you made me sneeze and laugh--and now? You +have already doffed your novelty, and some of you, I fear, are ready +to become truths, so immortal do they look, so pathetically honest, so +tedious! And was it ever otherwise? What then do we write and paint, +we mandarins with Chinese brush, we immortalisers of things which LEND +themselves to writing, what are we alone capable of painting? Alas, only +that which is just about to fade and begins to lose its odour! Alas, +only exhausted and departing storms and belated yellow sentiments! Alas, +only birds strayed and fatigued by flight, which now let themselves be +captured with the hand--with OUR hand! We immortalize what cannot live +and fly much longer, things only which are exhausted and mellow! And it +is only for your AFTERNOON, you, my written and painted thoughts, for +which alone I have colours, many colours, perhaps, many variegated +softenings, and fifty yellows and browns and greens and reds;--but +nobody will divine thereby how ye looked in your morning, you sudden +sparks and marvels of my solitude, you, my old, beloved--EVIL thoughts! + + + + +FROM THE HEIGHTS + +By F W Nietzsche + +Translated by L. A. Magnus + + + 1. + + MIDDAY of Life! Oh, season of delight! + My summer's park! + Uneaseful joy to look, to lurk, to hark-- + I peer for friends, am ready day and night,-- + Where linger ye, my friends? The time is right! + + 2. + + Is not the glacier's grey today for you + Rose-garlanded? + The brooklet seeks you, wind, cloud, with longing thread + And thrust themselves yet higher to the blue, + To spy for you from farthest eagle's view. + + 3. + + My table was spread out for you on high-- + Who dwelleth so + Star-near, so near the grisly pit below?-- + My realm--what realm hath wider boundary? + My honey--who hath sipped its fragrancy? + + 4. + + Friends, ye are there! Woe me,--yet I am not + He whom ye seek? + Ye stare and stop--better your wrath could speak! + I am not I? Hand, gait, face, changed? And what + I am, to you my friends, now am I not? + + 5. + + Am I an other? Strange am I to Me? + Yet from Me sprung? + A wrestler, by himself too oft self-wrung? + Hindering too oft my own self's potency, + Wounded and hampered by self-victory? + + 6. + + I sought where-so the wind blows keenest. There + I learned to dwell + Where no man dwells, on lonesome ice-lorn fell, + And unlearned Man and God and curse and prayer? + Became a ghost haunting the glaciers bare? + + 7. + + Ye, my old friends! Look! Ye turn pale, filled o'er + With love and fear! + Go! Yet not in wrath. Ye could ne'er live here. + Here in the farthest realm of ice and scaur, + A huntsman must one be, like chamois soar. + + 8. + + An evil huntsman was I? See how taut + My bow was bent! + Strongest was he by whom such bolt were sent-- + Woe now! That arrow is with peril fraught, + Perilous as none.--Have yon safe home ye sought! + + 9. + + Ye go! Thou didst endure enough, oh, heart;-- + Strong was thy hope; + Unto new friends thy portals widely ope, + Let old ones be. Bid memory depart! + Wast thou young then, now--better young thou art! + + 10. + + What linked us once together, one hope's tie-- + (Who now doth con + Those lines, now fading, Love once wrote thereon?)-- + Is like a parchment, which the hand is shy + To touch--like crackling leaves, all seared, all dry. + + 11. + + Oh! Friends no more! They are--what name for those?-- + Friends' phantom-flight + Knocking at my heart's window-pane at night, + Gazing on me, that speaks "We were" and goes,-- + Oh, withered words, once fragrant as the rose! + + 12. + + Pinings of youth that might not understand! + For which I pined, + Which I deemed changed with me, kin of my kind: + But they grew old, and thus were doomed and banned: + None but new kith are native of my land! + + 13. + + Midday of life! My second youth's delight! + My summer's park! + Unrestful joy to long, to lurk, to hark! + I peer for friends!--am ready day and night, + For my new friends. Come! Come! The time is right! + + 14. + + This song is done,--the sweet sad cry of rue + Sang out its end; + A wizard wrought it, he the timely friend, + The midday-friend,--no, do not ask me who; + At midday 'twas, when one became as two. + + 15. + + We keep our Feast of Feasts, sure of our bourne, + Our aims self-same: + The Guest of Guests, friend Zarathustra, came! + The world now laughs, the grisly veil was torn, + And Light and Dark were one that wedding-morn. + +PREFACE. + + +1 + +It is often enough, and always with great surprise, intimated to me that +there is something both ordinary and unusual in all my writings, from +the "Birth of Tragedy" to the recently published "Prelude to a +Philosophy of the Future": they all contain, I have been told, snares +and nets for short sighted birds, and something that is almost a +constant, subtle, incitement to an overturning of habitual opinions and +of approved customs. What!? Everything is merely--human--all too human? +With this exclamation my writings are gone through, not without a +certain dread and mistrust of ethic itself and not without a disposition +to ask the exponent of evil things if those things be not simply +misrepresented. My writings have been termed a school of distrust, still +more of disdain: also, and more happily, of courage, audacity even. And +in fact, I myself do not believe that anybody ever looked into the world +with a distrust as deep as mine, seeming, as I do, not simply the timely +advocate of the devil, but, to employ theological terms, an enemy and +challenger of God; and whosoever has experienced any of the consequences +of such deep distrust, anything of the chills and the agonies of +isolation to which such an unqualified difference of standpoint condemns +him endowed with it, will also understand how often I must have sought +relief and self-forgetfulness from any source--through any object of +veneration or enmity, of scientific seriousness or wanton lightness; +also why I, when I could not find what I was in need of, had to fashion +it for myself, counterfeiting it or imagining it (and what poet or +writer has ever done anything else, and what other purpose can all the +art in the world possibly have?) That which I always stood most in need +of in order to effect my cure and self-recovery was faith, faith enough +not to be thus isolated, not to look at life from so singular a point of +view--a magic apprehension (in eye and mind) of relationship and +equality, a calm confidence in friendship, a blindness, free from +suspicion and questioning, to two sidedness; a pleasure in externals, +superficialities, the near, the accessible, in all things possessed of +color, skin and seeming. Perhaps I could be fairly reproached with much +"art" in this regard, many fine counterfeitings; for example, that, +wisely or wilfully, I had shut my eyes to Schopenhauer's blind will +towards ethic, at a time when I was already clear sighted enough on the +subject of ethic; likewise that I had deceived myself concerning Richard +Wagner's incurable romanticism, as if it were a beginning and not an +end; likewise concerning the Greeks, likewise concerning the Germans and +their future--and there may be, perhaps, a long list of such likewises. +Granted, however, that all this were true, and with justice urged +against me, what does it signify, what can it signify in regard to how +much of the self-sustaining capacity, how much of reason and higher +protection are embraced in such self-deception?--and how much more +falsity is still necessary to me that I may therewith always reassure +myself regarding the luxury of my truth. Enough, I still live; and life +is not considered now apart from ethic; it _will_ [have] deception; it +thrives (lebt) on deception ... but am I not beginning to do all over +again what I have always done, I, the old immoralist, and bird +snarer--talk unmorally, ultramorally, "beyond good and evil"? + + +2 + +Thus, then, have I evolved for myself the "free spirits" to whom this +discouraging-encouraging work, under the general title "Human, All Too +Human," is dedicated. Such "free spirits" do not really exist and never +did exist. But I stood in need of them, as I have pointed out, in order +that some good might be mixed with my evils (illness, loneliness, +strangeness, _acedia_, incapacity): to serve as gay spirits and +comrades, with whom one may talk and laugh when one is disposed to talk +and laugh, and whom one may send to the devil when they grow wearisome. +They are some compensation for the lack of friends. That such free +spirits can possibly exist, that our Europe will yet number among her +sons of to-morrow or of the day after to-morrow, such a brilliant and +enthusiastic company, alive and palpable and not merely, as in my case, +fantasms and imaginary shades, I, myself, can by no means doubt. I see +them already coming, slowly, slowly. May it not be that I am doing a +little something to expedite their coming when I describe in advance the +influences under which I see them evolving and the ways along which they +travel? + + +3 + +It may be conjectured that a soul in which the type of "free spirit" can +attain maturity and completeness had its decisive and deciding event in +the form of a great emancipation or unbinding, and that prior to that +event it seemed only the more firmly and forever chained to its place +and pillar. What binds strongest? What cords seem almost unbreakable? In +the case of mortals of a choice and lofty nature they will be those of +duty: that reverence, which in youth is most typical, that timidity and +tenderness in the presence of the traditionally honored and the worthy, +that gratitude to the soil from which we sprung, for the hand that +guided us, for the relic before which we were taught to pray--their +sublimest moments will themselves bind these souls most strongly. The +great liberation comes suddenly to such prisoners, like an earthquake: +the young soul is all at once shaken, torn apart, cast forth--it +comprehends not itself what is taking place. An involuntary onward +impulse rules them with the mastery of command; a will, a wish are +developed to go forward, anywhere, at any price; a strong, dangerous +curiosity regarding an undiscovered world flames and flashes in all +their being. "Better to die than live _here_"--so sounds the tempting +voice: and this "here," this "at home" constitutes all they have +hitherto loved. A sudden dread and distrust of that which they loved, a +flash of contempt for that which is called their "duty," a mutinous, +wilful, volcanic-like longing for a far away journey, strange scenes and +people, annihilation, petrifaction, a hatred surmounting love, perhaps a +sacrilegious impulse and look backwards, to where they so long prayed +and loved, perhaps a flush of shame for what they did and at the same +time an exultation at having done it, an inner, intoxicating, +delightful tremor in which is betrayed the sense of victory--a victory? +over what? over whom? a riddle-like victory, fruitful in questioning and +well worth questioning, but the _first_ victory, for all--such things of +pain and ill belong to the history of the great liberation. And it is at +the same time a malady that can destroy a man, this first outbreak of +strength and will for self-destination, self-valuation, this will for +free will: and how much illness is forced to the surface in the frantic +strivings and singularities with which the freedman, the liberated seeks +henceforth to attest his mastery over things! He roves fiercely around, +with an unsatisfied longing and whatever objects he may encounter must +suffer from the perilous expectancy of his pride; he tears to pieces +whatever attracts him. With a sardonic laugh he overturns whatever he +finds veiled or protected by any reverential awe: he would see what +these things look like when they are overturned. It is wilfulness and +delight in the wilfulness of it, if he now, perhaps, gives his approval +to that which has heretofore been in ill repute--if, in curiosity and +experiment, he penetrates stealthily to the most forbidden things. In +the background during all his plunging and roaming--for he is as +restless and aimless in his course as if lost in a wilderness--is the +interrogation mark of a curiosity growing ever more dangerous. "Can we +not upset every standard? and is good perhaps evil? and God only an +invention and a subtlety of the devil? Is everything, in the last +resort, false? And if we are dupes are we not on that very account +dupers also? _must_ we not be dupers also?" Such reflections lead and +mislead him, ever further on, ever further away. Solitude, that dread +goddess and mater saeva cupidinum, encircles and besets him, ever more +threatening, more violent, more heart breaking--but who to-day knows +what solitude is? + + +4 + +From this morbid solitude, from the deserts of such trial years, the way +is yet far to that great, overflowing certainty and healthiness which +cannot dispense even with sickness as a means and a grappling hook of +knowledge; to that matured freedom of the spirit which is, in an equal +degree, self mastery and discipline of the heart, and gives access to +the path of much and various reflection--to that inner comprehensiveness +and self satisfaction of over-richness which precludes all danger that +the spirit has gone astray even in its own path and is sitting +intoxicated in some corner or other; to that overplus of plastic, +healing, imitative and restorative power which is the very sign of +vigorous health, that overplus which confers upon the free spirit the +perilous prerogative of spending a life in experiment and of running +adventurous risks: the past-master-privilege of the free spirit. In the +interval there may be long years of convalescence, years filled with +many hued painfully-bewitching transformations, dominated and led to the +goal by a tenacious will for health that is often emboldened to assume +the guise and the disguise of health. There is a middle ground to this, +which a man of such destiny can not subsequently recall without emotion; +he basks in a special fine sun of his own, with a feeling of birdlike +freedom, birdlike visual power, birdlike irrepressibleness, a something +extraneous (Drittes) in which curiosity and delicate disdain have +united. A "free spirit"--this refreshing term is grateful in any mood, +it almost sets one aglow. One lives--no longer in the bonds of love and +hate, without a yes or no, here or there indifferently, best pleased to +evade, to avoid, to beat about, neither advancing nor retreating. One is +habituated to the bad, like a person who all at once sees a fearful +hurly-burly _beneath_ him--and one was the counterpart of him who +bothers himself with things that do not concern him. As a matter of fact +the free spirit is bothered with mere things--and how many +things--which no longer _concern_ him. + + +5 + +A step further in recovery: and the free spirit draws near to life +again, slowly indeed, almost refractorily, almost distrustfully. There +is again warmth and mellowness: feeling and fellow feeling acquire +depth, lambent airs stir all about him. He almost feels: it seems as if +now for the first time his eyes are open to things _near_. He is in +amaze and sits hushed: for where had he been? These near and immediate +things: how changed they seem to him! He looks gratefully back--grateful +for his wandering, his self exile and severity, his lookings afar and +his bird flights in the cold heights. How fortunate that he has not, +like a sensitive, dull home body, remained always "in the house" and "at +home!" He had been beside himself, beyond a doubt. Now for the first +time he really sees himself--and what surprises in the process. What +hitherto unfelt tremors! Yet what joy in the exhaustion, the old +sickness, the relapses of the convalescent! How it delights him, +suffering, to sit still, to exercise patience, to lie in the sun! Who so +well as he appreciates the fact that there comes balmy weather even in +winter, who delights more in the sunshine athwart the wall? They are +the most appreciative creatures in the world, and also the most humble, +these convalescents and lizards, crawling back towards life: there are +some among them who can let no day slip past them without addressing +some song of praise to its retreating light. And speaking seriously, it +is a fundamental cure for all pessimism (the cankerous vice, as is well +known, of all idealists and humbugs), to become ill in the manner of +these free spirits, to remain ill quite a while and then bit by bit grow +healthy--I mean healthier. It is wisdom, worldly wisdom, to administer +even health to oneself for a long time in small doses. + + +6 + +About this time it becomes at last possible, amid the flash lights of a +still unestablished, still precarious health, for the free, the ever +freer spirit to begin to read the riddle of that great liberation, a +riddle which has hitherto lingered, obscure, well worth questioning, +almost impalpable, in his memory. If once he hardly dared to ask "why so +apart? so alone? renouncing all I loved? renouncing respect itself? why +this coldness, this suspicion, this hate for one's very virtues?"--now +he dares, and asks it loudly, already hearing the answer, "you had to +become master over yourself, master of your own good qualities. Formerly +they were your masters: but they should be merely your tools along with +other tools. You had to acquire power over your aye and no and learn to +hold and withhold them in accordance with your higher aims. You had to +grasp the perspective of every representation (Werthschätzung)--the +dislocation, distortion and the apparent end or teleology of the +horizon, besides whatever else appertains to the perspective: also the +element of demerit in its relation to opposing merit, and the whole +intellectual cost of every affirmative, every negative. You had to find +out the _inevitable_ error[1] in every Yes and in every No, error as +inseparable from life, life itself as conditioned by the perspective and +its inaccuracy.[1] Above all, you had to see with your own eyes where +the error[1] is always greatest: there, namely, where life is littlest, +narrowest, meanest, least developed and yet cannot help looking upon +itself as the goal and standard of things, and smugly and ignobly and +incessantly tearing to tatters all that is highest and greatest and +richest, and putting the shreds into the form of questions from the +standpoint of its own well being. You had to see with your own eyes the +problem of classification, (Rangordnung, regulation concerning rank and +station) and how strength and sweep and reach of perspective wax upward +together: You had"--enough, the free spirit knows henceforward which +"you had" it has obeyed and also what it now can do and what it now, for +the first time, _dare_. + +[1] Ungerechtigkeit, literally wrongfulness, injustice, unrighteousness. + + +7 + +Accordingly, the free spirit works out for itself an answer to that +riddle of its liberation and concludes by generalizing upon its +experience in the following fashion: "What I went through everyone must +go through" in whom any problem is germinated and strives to body itself +forth. The inner power and inevitability of this problem will assert +themselves in due course, as in the case of any unsuspected +pregnancy--long before the spirit has seen this problem in its true +aspect and learned to call it by its right name. Our destiny exercises +its influence over us even when, as yet, we have not learned its nature: +it is our future that lays down the law to our to-day. Granted, that it +is the problem of classification[2] of which we free spirits may say, +this is _our_ problem, yet it is only now, in the midday of our life, +that we fully appreciate what preparations, shifts, trials, ordeals, +stages, were essential to that problem before it could emerge to our +view, and why we had to go through the various and contradictory +longings and satisfactions of body and soul, as circumnavigators and +adventurers of that inner world called "man"; as surveyors of that +"higher" and of that "progression"[3] that is also called +"man"--crowding in everywhere, almost without fear, disdaining nothing, +missing nothing, testing everything, sifting everything and eliminating +the chance impurities--until at last we could say, we free spirits: +"Here--a _new_ problem! Here, a long ladder on the rungs of which we +ourselves have rested and risen, which we have actually been at times. +Here is a something higher, a something deeper, a something below us, a +vastly extensive order, (Ordnung) a comparative classification +(Rangordnung), that we perceive: here--_our_ problem!" + +[2] Rangordnung: the meaning is "the problem of grasping the relative +importance of things." + +[3] Uebereinander: one over another. + + +8 + +To what stage in the development just outlined the present book belongs +(or is assigned) is something that will be hidden from no augur or +psychologist for an instant. But where are there psychologists to-day? +In France, certainly; in Russia, perhaps; certainly not in Germany. +Grounds are not wanting, to be sure, upon which the Germans of to-day +may adduce this fact to their credit: unhappily for one who in this +matter is fashioned and mentored in an un-German school! This _German_ +book, which has found its readers in a wide circle of lands and +peoples--it has been some ten years on its rounds--and which must make +its way by means of any musical art and tune that will captivate the +foreign ear as well as the native--this book has been read most +indifferently in Germany itself and little heeded there: to what is that +due? "It requires too much," I have been told, "it addresses itself to +men free from the press of petty obligations, it demands fine and +trained perceptions, it requires a surplus, a surplus of time, of the +lightness of heaven and of the heart, of otium in the most unrestricted +sense: mere good things that we Germans of to-day have not got and +therefore cannot give." After so graceful a retort, my philosophy bids +me be silent and ask no more questions: at times, as the proverb says, +one remains a philosopher only because one says--nothing! + +Nice, Spring, 1886. + + + + +OF THE FIRST AND LAST THINGS. + + +1 + +=Chemistry of the Notions and the Feelings.=--Philosophical problems, in +almost all their aspects, present themselves in the same interrogative +formula now that they did two thousand years ago: how can a thing +develop out of its antithesis? for example, the reasonable from the +non-reasonable, the animate from the inanimate, the logical from the +illogical, altruism from egoism, disinterestedness from greed, truth +from error? The metaphysical philosophy formerly steered itself clear of +this difficulty to such extent as to repudiate the evolution of one +thing from another and to assign a miraculous origin to what it deemed +highest and best, due to the very nature and being of the +"thing-in-itself." The historical philosophy, on the other hand, which +can no longer be viewed apart from physical science, the youngest of all +philosophical methods, discovered experimentally (and its results will +probably always be the same) that there is no antithesis whatever, +except in the usual exaggerations of popular or metaphysical +comprehension, and that an error of the reason is at the bottom of such +contradiction. According to its explanation, there is, strictly +speaking, neither unselfish conduct, nor a wholly disinterested point of +view. Both are simply sublimations in which the basic element seems +almost evaporated and betrays its presence only to the keenest +observation. All that we need and that could possibly be given us in the +present state of development of the sciences, is a chemistry of the +moral, religious, aesthetic conceptions and feeling, as well as of those +emotions which we experience in the affairs, great and small, of society +and civilization, and which we are sensible of even in solitude. But +what if this chemistry established the fact that, even in _its_ domain, +the most magnificent results were attained with the basest and most +despised ingredients? Would many feel disposed to continue such +investigations? Mankind loves to put by the questions of its origin and +beginning: must one not be almost inhuman in order to follow the +opposite course? + + +2 + +=The Traditional Error of Philosophers.=--All philosophers make the +common mistake of taking contemporary man as their starting point and of +trying, through an analysis of him, to reach a conclusion. "Man" +involuntarily presents himself to them as an aeterna veritas as a +passive element in every hurly-burly, as a fixed standard of things. Yet +everything uttered by the philosopher on the subject of man is, in the +last resort, nothing more than a piece of testimony concerning man +during a very limited period of time. Lack of the historical sense is +the traditional defect in all philosophers. Many innocently take man in +his most childish state as fashioned through the influence of certain +religious and even of certain political developments, as the permanent +form under which man must be viewed. They will not learn that man has +evolved,[4] that the intellectual faculty itself is an evolution, +whereas some philosophers make the whole cosmos out of this intellectual +faculty. But everything essential in human evolution took place aeons +ago, long before the four thousand years or so of which we know +anything: during these man may not have changed very much. However, the +philosopher ascribes "instinct" to contemporary man and assumes that +this is one of the unalterable facts regarding man himself, and hence +affords a clue to the understanding of the universe in general. The +whole teleology is so planned that man during the last four thousand +years shall be spoken of as a being existing from all eternity, and +with reference to whom everything in the cosmos from its very inception +is naturally ordered. Yet everything evolved: there are no eternal facts +as there are no absolute truths. Accordingly, historical philosophising +is henceforth indispensable, and with it honesty of judgment. + +[4] geworden. + + +3 + +=Appreciation of Simple Truths.=--It is the characteristic of an +advanced civilization to set a higher value upon little, simple truths, +ascertained by scientific method, than upon the pleasing and magnificent +errors originating in metaphysical and æsthetical epochs and peoples. To +begin with, the former are spoken of with contempt as if there could be +no question of comparison respecting them, so rigid, homely, prosaic and +even discouraging is the aspect of the first, while so beautiful, +decorative, intoxicating and perhaps beatific appear the last named. +Nevertheless, the hardwon, the certain, the lasting and, therefore, the +fertile in new knowledge, is the higher; to hold fast to it is manly and +evinces courage, directness, endurance. And not only individual men but +all mankind will by degrees be uplifted to this manliness when they are +finally habituated to the proper appreciation of tenable, enduring +knowledge and have lost all faith in inspiration and in the miraculous +revelation of truth. The reverers of forms, indeed, with their standards +of beauty and taste, may have good reason to laugh when the appreciation +of little truths and the scientific spirit begin to prevail, but that +will be only because their eyes are not yet opened to the charm of the +utmost simplicity of form or because men though reared in the rightly +appreciative spirit, will still not be fully permeated by it, so that +they continue unwittingly imitating ancient forms (and that ill enough, +as anybody does who no longer feels any interest in a thing). Formerly +the mind was not brought into play through the medium of exact thought. +Its serious business lay in the working out of forms and symbols. That +has now changed. Any seriousness in symbolism is at present the +indication of a deficient education. As our very acts become more +intellectual, our tendencies more rational, and our judgment, for +example, as to what seems reasonable, is very different from what it was +a hundred years ago: so the forms of our lives grow ever more +intellectual and, to the old fashioned eye, perhaps, uglier, but only +because it cannot see that the richness of inner, rational beauty always +spreads and deepens, and that the inner, rational aspect of all things +should now be of more consequence to us than the most beautiful +externality and the most exquisite limning. + + +4 + +=Astrology and the Like.=--It is presumable that the objects of the +religious, moral, aesthetic and logical notions pertain simply to the +superficialities of things, although man flatters himself with the +thought that here at least he is getting to the heart of the cosmos. He +deceives himself because these things have power to make him so happy +and so wretched, and so he evinces, in this respect, the same conceit +that characterises astrology. Astrology presupposes that the heavenly +bodies are regulated in their movements in harmony with the destiny of +mortals: the moral man presupposes that that which concerns himself most +nearly must also be the heart and soul of things. + + +5 + +=Misconception of Dreams.=--In the dream, mankind, in epochs of crude +primitive civilization, thought they were introduced to a second, +substantial world: here we have the source of all metaphysic. Without +the dream, men would never have been incited to an analysis of the +world. Even the distinction between soul and body is wholly due to the +primitive conception of the dream, as also the hypothesis of the +embodied soul, whence the development of all superstition, and also, +probably, the belief in god. "The dead still live: for they appear to +the living in dreams." So reasoned mankind at one time, and through many +thousands of years. + + +6 + +=The Scientific Spirit Prevails only Partially, not Wholly.=--The +specialized, minutest departments of science are dealt with purely +objectively. But the general universal sciences, considered as a great, +basic unity, posit the question--truly a very living question--: to what +purpose? what is the use? Because of this reference to utility they are, +as a whole, less impersonal than when looked at in their specialized +aspects. Now in the case of philosophy, as forming the apex of the +scientific pyramid, this question of the utility of knowledge is +necessarily brought very conspicuously forward, so that every philosophy +has, unconsciously, the air of ascribing the highest utility to itself. +It is for this reason that all philosophies contain such a great amount +of high flying metaphysic, and such a shrinking from the seeming +insignificance of the deliverances of physical science: for the +significance of knowledge in relation to life must be made to appear as +great as possible. This constitutes the antagonism between the +specialties of science and philosophy. The latter aims, as art aims, at +imparting to life and conduct the utmost depth and significance: in the +former mere knowledge is sought and nothing else--whatever else be +incidentally obtained. Heretofore there has never been a philosophical +system in which philosophy itself was not made the apologist of +knowledge [in the abstract]. On this point, at least, each is optimistic +and insists that to knowledge the highest utility must be ascribed. They +are all under the tyranny of logic, which is, from its very nature, +optimism. + + +7 + +=The Discordant Element in Science.=--Philosophy severed itself from +science when it put the question: what is that knowledge of the world +and of life through which mankind may be made happiest? This happened +when the Socratic school arose: with the standpoint of _happiness_ the +arteries of investigating science were compressed too tightly to permit +of any circulation of the blood--and are so compressed to-day. + + +8 + +=Pneumatic Explanation of Nature.=[5]--Metaphysic reads the message of +nature as if it were written purely pneumatically, as the church and its +learned ones formerly did where the bible was concerned. It requires a +great deal of expertness to apply to nature the same strict science of +interpretation that the philologists have devised for all literature, +and to apply it for the purpose of a simple, direct interpretation of +the message, and at the same time, not bring out a double meaning. But, +as in the case of books and literature, errors of exposition are far +from being completely eliminated, and vestiges of allegorical and +mystical interpretations are still to be met with in the most cultivated +circles, so where nature is concerned the case is--actually much worse. + +[5] Pneumatic is here used in the sense of spiritual. Pneuma being the +Greek word in the New Testament for the Holy Spirit.--Ed. + + +9 + +=Metaphysical World.=--It is true, there may be a metaphysical world; +the absolute possibility of it can scarcely be disputed. We see all +things through the medium of the human head and we cannot well cut off +this head: although there remains the question what part of the world +would be left after it had been cut off. But that is a purely abstract +scientific problem and one not much calculated to give men uneasiness: +yet everything that has heretofore made metaphysical assumptions +valuable, fearful or delightful to men, all that gave rise to them is +passion, error and self deception: the worst systems of knowledge, not +the best, pin their tenets of belief thereto. When such methods are once +brought to view as the basis of all existing religions and metaphysics, +they are already discredited. There always remains, however, the +possibility already conceded: but nothing at all can be made out of +that, to say not a word about letting happiness, salvation and life hang +upon the threads spun from such a possibility. Accordingly, nothing +could be predicated of the metaphysical world beyond the fact that it is +an elsewhere,[6] another sphere, inaccessible and incomprehensible to +us: it would become a thing of negative properties. Even were the +existence of such a world absolutely established, it would nevertheless +remain incontrovertible that of all kinds of knowledge, knowledge of +such a world would be of least consequence--of even less consequence +than knowledge of the chemical analysis of water would be to a storm +tossed mariner. + +[6] Anderssein. + + +10 + +=The Harmlessness of Metaphysic in the Future.=--As soon as religion, +art and ethics are so understood that a full comprehension of them can +be gained without taking refuge in the postulates of metaphysical +claptrap at any point in the line of reasoning, there will be a complete +cessation of interest in the purely theoretical problem of the "thing in +itself" and the "phenomenon." For here, too, the same truth applies: in +religion, art and ethics we are not concerned with the "essence of the +cosmos".[7] We are in the sphere of pure conception. No presentiment [or +intuition] can carry us any further. With perfect tranquility the +question of how our conception of the world could differ so sharply from +the actual world as it is manifest to us, will be relegated to the +physiological sciences and to the history of the evolution of ideas and +organisms. + +[7] "Wesen der Welt an sich." + + +11 + +=Language as a Presumptive Science.=--The importance of language in the +development of civilization consists in the fact that by means of it +man placed one world, his own, alongside another, a place of leverage +that he thought so firm as to admit of his turning the rest of the +cosmos on a pivot that he might master it. In so far as man for ages +looked upon mere ideas and names of things as upon aeternae veritates, +he evinced the very pride with which he raised himself above the brute. +He really supposed that in language he possessed a knowledge of the +cosmos. The language builder was not so modest as to believe that he was +only giving names to things. On the contrary he thought he embodied the +highest wisdom concerning things in [mere] words; and, in truth, +language is the first movement in all strivings for wisdom. Here, too, +it is _faith in ascertained truth_[8] from which the mightiest fountains +of strength have flowed. Very tardily--only now--it dawns upon men that +they have propagated a monstrous error in their belief in language. +Fortunately, it is too late now to arrest and turn back the evolutionary +process of the reason, which had its inception in this belief. Logic +itself rests upon assumptions to which nothing in the world of reality +corresponds. For example, the correspondence of certain things to one +another and the identity of those things at different periods of time +are assumptions pure and simple, but the science of logic originated in +the positive belief that they were not assumptions at all but +established facts. It is the same with the science of mathematics which +certainly would never have come into existence if mankind had known from +the beginning that in all nature there is no perfectly straight line, no +true circle, no standard of measurement. + +[8] Glaube an die gefundene Wahrheit, as distinguished from faith in +what is taken on trust as truth. + + +12 + +=Dream and Civilization.=--The function of the brain which is most +encroached upon in slumber is the memory; not that it is wholly +suspended, but it is reduced to a state of imperfection as, in primitive +ages of mankind, was probably the case with everyone, whether waking or +sleeping. Uncontrolled and entangled as it is, it perpetually confuses +things as a result of the most trifling similarities, yet in the same +mental confusion and lack of control the nations invented their +mythologies, while nowadays travelers habitually observe how prone the +savage is to forgetfulness, how his mind, after the least exertion of +memory, begins to wander and lose itself until finally he utters +falsehood and nonsense from sheer exhaustion. Yet, in dreams, we all +resemble this savage. Inadequacy of distinction and error of comparison +are the basis of the preposterous things we do and say in dreams, so +that when we clearly recall a dream we are startled that so much idiocy +lurks within us. The absolute distinctness of all dream-images, due to +implicit faith in their substantial reality, recalls the conditions in +which earlier mankind were placed, for whom hallucinations had +extraordinary vividness, entire communities and even entire nations +laboring simultaneously under them. Therefore: in sleep and in dream we +make the pilgrimage of early mankind over again. + + +13 + +=Logic of the Dream.=--During sleep the nervous system, through various +inner provocatives, is in constant agitation. Almost all the organs act +independently and vigorously. The blood circulates rapidly. The posture +of the sleeper compresses some portions of the body. The coverlets +influence the sensations in different ways. The stomach carries on the +digestive process and acts upon other organs thereby. The intestines are +in motion. The position of the head induces unaccustomed action. The +feet, shoeless, no longer pressing the ground, are the occasion of other +sensations of novelty, as is, indeed, the changed garb of the entire +body. All these things, following the bustle and change of the day, +result, through their novelty, in a movement throughout the entire +system that extends even to the brain functions. Thus there are a +hundred circumstances to induce perplexity in the mind, a questioning as +to the cause of this excitation. Now, the dream is a _seeking and +presenting of reasons_ for these excitations of feeling, of the supposed +reasons, that is to say. Thus, for example, whoever has his feet bound +with two threads will probably dream that a pair of serpents are coiled +about his feet. This is at first a hypothesis, then a belief with an +accompanying imaginative picture and the argument: "these snakes must be +the _causa_ of those sensations which I, the sleeper, now have." So +reasons the mind of the sleeper. The conditions precedent, as thus +conjectured, become, owing to the excitation of the fancy, present +realities. Everyone knows from experience how a dreamer will transform +one piercing sound, for example, that of a bell, into another of quite a +different nature, say, the report of cannon. In his dream he becomes +aware first of the effects, which he explains by a subsequent hypothesis +and becomes persuaded of the purely conjectural nature of the sound. But +how comes it that the mind of the dreamer goes so far astray when the +same mind, awake, is habitually cautious, careful, and so conservative +in its dealings with hypotheses? why does the first plausible +hypothesis of the cause of a sensation gain credit in the dreaming +state? (For in a dream we look upon that dream as reality, that is, we +accept our hypotheses as fully established). I have no doubt that as men +argue in their dreams to-day, mankind argued, even in their waking +moments, for thousands of years: the first _causa_, that occurred to the +mind with reference to anything that stood in need of explanation, was +accepted as the true explanation and served as such. (Savages show the +same tendency in operation, as the reports of travelers agree). In the +dream this atavistic relic of humanity manifests its existence within +us, for it is the foundation upon which the higher rational faculty +developed itself and still develops itself in every individual. Dreams +carry us back to the earlier stages of human culture and afford us a +means of understanding it more clearly. Dream thought comes so easily to +us now because we are so thoroughly trained to it through the +interminable stages of evolution during which this fanciful and facile +form of theorising has prevailed. To a certain extent the dream is a +restorative for the brain, which, during the day, is called upon to meet +the many demands for trained thought made upon it by the conditions of a +higher civilization.--We may, if we please, become sensible, even in our +waking moments, of a condition that is as a door and vestibule to +dreaming. If we close our eyes the brain immediately conjures up a +medley of impressions of light and color, apparently a sort of imitation +and echo of the impressions forced in upon the brain during its waking +moments. And now the mind, in co-operation with the imagination, +transforms this formless play of light and color into definite figures, +moving groups, landscapes. What really takes place is a sort of +reasoning from effect back to cause. As the brain inquires: whence these +impressions of light and color? it posits as the inducing causes of such +lights and colors, those shapes and figures. They serve the brain as the +occasions of those lights and colors because the brain, when the eyes +are open and the senses awake, is accustomed to perceiving the cause of +every impression of light and color made upon it. Here again the +imagination is continually interposing its images inasmuch as it +participates in the production of the impressions made through the +senses day by day: and the dream-fancy does exactly the same thing--that +is, the presumed cause is determined from the effect and _after_ the +effect: all this, too, with extraordinary rapidity, so that in this +matter, as in a matter of jugglery or sleight-of-hand, a confusion of +the mind is produced and an after effect is made to appear a +simultaneous action, an inverted succession of events, even.--From +these considerations we can see how _late_ strict, logical thought, the +true notion of cause and effect must have been in developing, since our +intellectual and rational faculties to this very day revert to these +primitive processes of deduction, while practically half our lifetime is +spent in the super-inducing conditions.--Even the poet, the artist, +ascribes to his sentimental and emotional states causes which are not +the true ones. To that extent he is a reminder of early mankind and can +aid us in its comprehension. + + +14 + +=Association.=[9]--All strong feelings are associated with a variety of +allied sentiments and emotions. They stir up the memory at the same +time. When we are under their influence we are reminded of similar +states and we feel a renewal of them within us. Thus are formed habitual +successions of feelings and notions, which, at last, when they follow +one another with lightning rapidity are no longer felt as complexities +but as unities. In this sense we hear of moral feelings, of religious +feelings, as if they were absolute unities. In reality they are streams +with a hundred sources and tributaries. Here again, the unity of the +word speaks nothing for the unity of the thing. + +[9] Miterklingen: to sound simultaneously with. + + +15 + +=No Within and Without in the World.=[10]--As Democritus transferred the +notions above and below to limitless space, where they are destitute of +meaning, so the philosophers do generally with the idea "within and +without," as regards the form and substance (Wesen und Erscheinung) of +the world. What they claim is that through the medium of profound +feelings one can penetrate deep into the soul of things (Innre), draw +close to the heart of nature. But these feelings are deep only in so far +as with them are simultaneously aroused, although almost imperceptibly, +certain complicated groups of thoughts (Gedankengruppen) which we call +deep: a feeling is deep because we deem the thoughts accompanying it +deep. But deep thought can nevertheless be very widely sundered from +truth, as for instance every metaphysical thought. Take from deep +feeling the element of thought blended with it and all that remains is +_strength_ of feeling which is no voucher for the validity of +knowledge, as intense faith is evidence only of its own intensity and +not of the truth of that in which the faith is felt. + +[10] Kein Innen und Aussen in der Welt: the above translation may seem +too literal but some dispute has arisen concerning the precise idea the +author means to convey. + + +16 + +=Phenomenon and Thing-in-Itself.=--The philosophers are in the habit of +placing themselves in front of life and experience--that which they call +the world of phenomena--as if they were standing before a picture that +is unrolled before them in its final completeness. This panorama, they +think, must be studied in every detail in order to reach some conclusion +regarding the object represented by the picture. From effect, +accordingly is deduced cause and from cause is deduced the +unconditioned. This process is generally looked upon as affording the +all sufficient explanation of the world of phenomena. On the other hand +one must, (while putting the conception of the metaphysical distinctly +forward as that of the unconditioned, and consequently of the +unconditioning) absolutely deny any connection between the unconditioned +(of the metaphysical world) and the world known to us: so that +throughout phenomena there is no manifestation of the thing-in-itself, +and getting from one to the other is out of the question. Thus is left +quite ignored the circumstance that the picture--that which we now call +life and experience--is a gradual evolution, is, indeed, still in +process of evolution and for that reason should not be regarded as an +enduring whole from which any conclusion as to its author (the +all-sufficient reason) could be arrived at, or even pronounced out of +the question. It is because we have for thousands of years looked into +the world with moral, aesthetic, religious predispositions, with blind +prejudice, passion or fear, and surfeited ourselves with indulgence in +the follies of illogical thought, that the world has gradually become so +wondrously motley, frightful, significant, soulful: it has taken on +tints, but we have been the colorists: the human intellect, upon the +foundation of human needs, of human passions, has reared all these +"phenomena" and injected its own erroneous fundamental conceptions into +things. Late, very late, the human intellect checks itself: and now the +world of experience and the thing-in-itself seem to it so severed and so +antithetical that it denies the possibility of one's hinging upon the +other--or else summons us to surrender our intellect, our personal will, +to the secret and the awe-inspiring in order that thereby we may attain +certainty of certainty hereafter. Again, there are those who have +combined all the characteristic features of our world of +phenomena--that is, the conception of the world which has been formed +and inherited through a series of intellectual vagaries--and instead of +holding the intellect responsible for it all, have pronounced the very +nature of things accountable for the present very sinister aspect of the +world, and preached annihilation of existence. Through all these views +and opinions the toilsome, steady process of science (which now for the +first time begins to celebrate its greatest triumph in the genesis of +thought) will definitely work itself out, the result, being, perhaps, to +the following effect: That which we now call the world is the result of +a crowd of errors and fancies which gradually developed in the general +evolution of organic nature, have grown together and been transmitted to +us as the accumulated treasure of all the past--as the _treasure_, for +whatever is worth anything in our humanity rests upon it. From this +world of conception it is in the power of science to release us only to +a slight extent--and this is all that could be wished--inasmuch as it +cannot eradicate the influence of hereditary habits of feeling, but it +can light up by degrees the stages of the development of that world of +conception, and lift us, at least for a time, above the whole spectacle. +Perhaps we may then perceive that the thing-in-itself is a meet subject +for Homeric laughter: that it seemed so much, everything, indeed, and +is really a void--void, that is to say, of meaning. + + +17 + +=Metaphysical Explanation.=--Man, when he is young, prizes metaphysical +explanations, because they make him see matters of the highest import in +things he found disagreeable or contemptible: and if he is not satisfied +with himself, this feeling of dissatisfaction is soothed when he sees +the most hidden world-problem or world-pain in that which he finds so +displeasing in himself. To feel himself more unresponsible and at the +same time to find things (Dinge) more interesting--that is to him the +double benefit he owes to metaphysics. Later, indeed, he acquires +distrust of the whole metaphysical method of explaining things: he then +perceives, perhaps, that those effects could have been attained just as +well and more scientifically by another method: that physical and +historical explanations would, at least, have given that feeling of +freedom from personal responsibility just as well, while interest in +life and its problems would be stimulated, perhaps, even more. + + +18 + +=The Fundamental Problems of Metaphysics.=--If a history of the +development of thought is ever written, the following proposition, +advanced by a distinguished logician, will be illuminated with a new +light: "The universal, primordial law of the apprehending subject +consists in the inner necessity of cognizing every object by itself, as +in its essence a thing unto itself, therefore as self-existing and +unchanging, in short, as a substance." Even this law, which is here +called "primordial," is an evolution: it has yet to be shown how +gradually this evolution takes place in lower organizations: how the +dim, mole eyes of such organizations see, at first, nothing but a blank +sameness: how later, when the various excitations of desire and aversion +manifest themselves, various substances are gradually distinguished, but +each with an attribute, that is, a special relationship to such an +organization. The first step towards the logical is judgment, the +essence of which, according to the best logicians, is belief. At the +foundation of all beliefs lie sensations of pleasure or pain in relation +to the apprehending subject. A third feeling, as the result of two +prior, single, separate feelings, is judgment in its crudest form. We +organic beings are primordially interested by nothing whatever in any +thing (Ding) except its relation to ourselves with reference to pleasure +and pain. Between the moments in which we are conscious of this +relation, (the states of feeling) lie the moments of rest, of +not-feeling: then the world and every thing (Ding) have no interest for +us: we observe no change in them (as at present a person absorbed in +something does not notice anyone passing by). To plants all things are, +as a rule, at rest, eternal, every object like itself. From the period +of lower organisms has been handed down to man the belief that there are +like things (gleiche Dinge): only the trained experience attained +through the most advanced science contradicts this postulate. The +primordial belief of all organisms is, perhaps, that all the rest of the +world is one thing and motionless.--Furthest away from this first step +towards the logical is the notion of causation: even to-day we think +that all our feelings and doings are, at bottom, acts of the free will; +when the sentient individual contemplates himself he deems every +feeling, every change, a something isolated, disconnected, that is to +say, unqualified by any thing; it comes suddenly to the surface, +independent of anything that went before or came after. We are hungry, +but originally we do not know that the organism must be nourished: on +the contrary that feeling seems to manifest itself without reason or +purpose; it stands out by itself and seems quite independent. Therefore: +the belief in the freedom of the will is a primordial error of +everything organic as old as the very earliest inward prompting of the +logical faculty; belief in unconditioned substances and in like things +(gleiche Dinge) is also a primordial and equally ancient error of +everything organic. Inasmuch as all metaphysic has concerned itself +particularly with substance and with freedom of the will, it should be +designated as the science that deals with the fundamental errors of +mankind as if they were fundamental truths. + + +19 + +=Number.=--The invention of the laws of number has as its basis the +primordial and prior-prevailing delusion that many like things exist +(although in point of fact there is no such thing is a duplicate), or +that, at least, there are things (but there is no "thing"). The +assumption of plurality always presupposes that _something_ exists which +manifests itself repeatedly, but just here is where the delusion +prevails; in this very matter we feign realities, unities, that have no +existence. Our feelings, notions, of space and time are false for they +lead, when duly tested, to logical contradictions. In all scientific +demonstrations we always unavoidably base our calculation upon some +false standards [of duration or measurement] but as these standards are +at least _constant_, as, for example, our notions of time and space, the +results arrived at by science possess absolute accuracy and certainty in +their relationship to one another: one can keep on building upon +them--until is reached that final limit at which the erroneous +fundamental conceptions, (the invariable breakdown) come into conflict +with the results established--as, for example, in the case of the atomic +theory. Here we always find ourselves obliged to give credence to a +"thing" or material "substratum" that is set in motion, although, at the +same time, the whole scientific programme has had as its aim the +resolving of everything material into motions [themselves]: here again +we distinguish with our feeling [that which does the] moving and [that +which is] moved,[11] and we never get out of this circle, because the +belief in things[12] has been from time immemorial rooted in our +nature.--When Kant says "the intellect does not derive its laws from +nature, but dictates them to her" he states the full truth as regards +the _idea of nature_ which we form (nature = world, as notion, that is, +as error) but which is merely the synthesis of a host of errors of the +intellect. To a world not [the outcome of] our conception, the laws of +number are wholly inapplicable: such laws are valid only in the world of +mankind. + +[11] Wir scheiden auch hier noch mit unserer Empfindung Bewegendes und +Bewegtes. + +[12] Glaube an Dinge. + + +20 + +=Some Backward Steps.=--One very forward step in education is taken when +man emerges from his superstitious and religious ideas and fears and, +for instance, no longer believes in the dear little angels or in +original sin, and has stopped talking about the salvation of the soul: +when he has taken this step to freedom he has, nevertheless, through the +utmost exertion of his mental power, to overcome metaphysics. Then a +backward movement is necessary: he must appreciate the historical +justification, and to an equal extent the psychological considerations, +in such a movement. He must understand that the greatest advances made +by mankind have resulted from such a course and that without this very +backward movement the highest achievements of man hitherto would have +been impossible.--With regard to philosophical metaphysics I see ever +more and more who have arrived at the negative goal (that all positive +metaphysic is a delusion) but as yet very few who go a few steps +backward: one should look out over the last rungs of the ladder, but not +try to stand on them, that is to say. The most advanced as yet go only +far enough to free themselves from metaphysic and look back at it with +an air of superiority: whereas here, no less than in the hippodrome, it +is necessary to turn around in order to reach the end of the course. + + +21 + +=Presumable [Nature of the] Victory of Doubt.=--Let us assume for a +moment the validity of the skeptical standpoint: granted that there is +no metaphysical world, and that all the metaphysical explanations of the +only world we know are useless to us, how would we then contemplate men +and things? [Menschen und Dinge]. This can be thought out and it is +worth while doing so, even if the question whether anything metaphysical +has ever been demonstrated by or through Kant and Schopenhauer, be put +altogether aside. For it is, to all appearances, highly probable that +men, on this point, will be, in the mass, skeptical. The question thus +becomes: what sort of a notion will human society, under the influence +of such a state of mind, form of itself? Perhaps the _scientific +demonstration_ of any metaphysical world is now so difficult that +mankind will never be free from a distrust of it. And when there is +formed a feeling of distrust of metaphysics, the results are, in the +mass, the same as if metaphysics were refuted altogether and _could_ no +longer be believed. In both cases the historical question, with regard +to an unmetaphysical disposition in mankind, remains the same. + + +22 + +=Disbelief in the "monumentum aere perennius".=[13]--A decided +disadvantage, attending the termination of metaphysical modes of +thought, is that the individual fixes his mind too attentively upon his +own brief lifetime and feels no strong inducement to aid in the +foundation of institutions capable of enduring for centuries: he wishes +himself to gather the fruit from the tree that he plants and +consequently he no longer plants those trees which require centuries of +constant cultivation and are destined to afford shade to generation +after generation in the future. For metaphysical views inspire the +belief that in them is afforded the final sure foundation upon which +henceforth the whole future of mankind may rest and be built up: the +individual promotes his own salvation; when, for example, he builds a +church or a monastery he is of opinion that he is doing something for +the salvation of his immortal soul:--Can science, as well, inspire such +faith in the efficacy of her results? In actual fact, science requires +doubt and distrust as her surest auxiliaries; nevertheless, the sum of +the irresistible (that is all the onslaughts of skepticism, all the +disintegrating effects of surviving truths) can easily become so great +(as, for instance, in the case of hygienic science) as to inspire the +determination to build "eternal" works upon it. At present the contrast +between our excitated ephemeral existence and the tranquil repose of +metaphysical epochs is too great because both are as yet in too close +juxtaposition. The individual man himself now goes through too many +stages of inner and outer evolution for him to venture to make a plan +even for his life time alone. A perfectly modern man, indeed, who wants +to build himself a house feels as if he were walling himself up alive in +a mausoleum. + +[13] Monument more enduring than brass: Horace, Odes III:XXX. + + +23 + +=Age of Comparison.=--The less men are bound by tradition, the greater +is the inner activity of motives, the greater, correspondingly, the +outer restlessness, the promiscuous flow of humanity, the polyphony of +strivings. Who now feels any great impulse to establish himself and his +posterity in a particular place? For whom, moreover, does there exist, +at present, any strong tie? As all the methods of the arts were copied +from one another, so were all the methods and advancements of moral +codes, of manners, of civilizations.--Such an age derives its +significance from the fact that in it the various ideas, codes, manners +and civilizations can be compared and experienced side by side; which +was impossible at an earlier period in view of the localised nature of +the rule of every civilization, corresponding to the limitation of all +artistic effects by time and place. To-day the growth of the aesthetic +feeling is decided, owing to the great number of [artistic] forms which +offer themselves for comparison. The majority--those that are condemned +by the method of comparison--will be allowed to die out. In the same way +there is to-day taking place a selection of the forms and customs of the +higher morality which can result only in the extinction of the vulgar +moralities. This is the age of comparison! That is its glory--but also +its pain. Let us not, however shrink from this pain. Rather would we +comprehend the nature of the task imposed upon us by our age as +adequately as we can: posterity will bless us for doing so--a posterity +that knows itself to be [developed] through and above the narrow, early +race-civilizations as well as the culture-civilization of comparison, +but yet looks gratefully back upon both as venerable monuments of +antiquity. + + +24 + +=Possibility of Progress.=--When a master of the old civilization (den +alten Cultur) vows to hold no more discussion with men who believe in +progress, he is quite right. For the old civilization[14] has its +greatness and its advantages behind it, and historic training forces one +to acknowledge that it can never again acquire vigor: only intolerable +stupidity or equally intolerable fanaticism could fail to perceive this +fact. But men may consciously determine to evolve to a new civilization +where formerly they evolved unconsciously and accidentally. They can now +devise better conditions for the advancement of mankind, for their +nourishment, training and education, they can administer the earth as an +economic power, and, particularly, compare the capacities of men and +select them accordingly. This new, conscious civilization is killing the +other which, on the whole, has led but an unreflective animal and plant +life: it is also destroying the doubt of progress itself--progress is +possible. I mean: it is hasty and almost unreflective to assume that +progress must _necessarily_ take place: but how can it be doubted that +progress is possible? On the other hand, progress in the sense and along +the lines of the old civilization is not even conceivable. If romantic +fantasy employs the word progress in connection with certain aims and +ends identical with those of the circumscribed primitive national +civilizations, the picture presented of progress is always borrowed from +the past. The idea and the image of progress thus formed are quite +without originality. + +[14] Cultur, culture, civilisation etc., but there is no exact English +equivalent. + + +25 + +=Private Ethics and World Ethics.=--Since the extinction of the belief +that a god guides the general destiny of the world and, notwithstanding +all the contortions and windings of the path of mankind, leads it +gloriously forward, men must shape oecumenical, world-embracing ends for +themselves. The older ethics, namely Kant's, required of the individual +such a course of conduct as he wishes all men to follow. This evinces +much simplicity--as if any individual could determine off hand what +course of conduct would conduce to the welfare of humanity, and what +course of conduct is preëminently desirable! This is a theory like that +of freedom of competition, which takes it for granted that the general +harmony [of things] _must_ prevail of itself in accordance with some +inherent law of betterment or amelioration. It may be that a later +contemplation of the needs of mankind will reveal that it is by no means +desirable that all men should regulate their conduct according to the +same principle; it may be best, from the standpoint of certain ends yet +to be attained, that men, during long periods should regulate their +conduct with reference to special, and even, in certain circumstances, +evil, objects. At any rate, if mankind is not to be led astray by such a +universal rule of conduct, it behooves it to attain a _knowledge of the +condition of culture_ that will serve as a scientific standard of +comparison in connection with cosmical ends. Herein is comprised the +tremendous mission of the great spirits of the next century. + + +26 + +=Reaction as Progress.=--Occasionally harsh, powerful, impetuous, yet +nevertheless backward spirits, appear, who try to conjure back some past +era in the history of mankind: they serve as evidence that the new +tendencies which they oppose, are not yet potent enough, that there is +something lacking in them: otherwise they [the tendencies] would better +withstand the effects of this conjuring back process. Thus Luther's +reformation shows that in his century all the impulses to freedom of the +spirit were still uncertain, lacking in vigor, and immature. Science +could not yet rear her head. Indeed the whole Renaissance appears but as +an early spring smothered in snow. But even in the present century +Schopenhauer's metaphysic shows that the scientific spirit is not yet +powerful enough: for the whole mediaeval Christian world-standpoint +(Weltbetrachtung) and conception of man (Mensch-Empfindung)[15] once +again, notwithstanding the slowly wrought destruction of all Christian +dogma, celebrated a resurrection in Schopenhauer's doctrine. There is +much science in his teaching although the science does not dominate, +but, instead of it, the old, trite "metaphysical necessity." It is one +of the greatest and most priceless advantages of Schopenhauer's teaching +that by it our feelings are temporarily forced back to those old human +and cosmical standpoints to which no other path could conduct us so +easily. The gain for history and justice is very great. I believe that +without Schopenhauer's aid it would be no easy matter for anyone now to +do justice to Christianity and its Asiatic relatives--a thing impossible +as regards the christianity that still survives. After according this +great triumph to justice, after we have corrected in so essential a +respect the historical point of view which the age of learning brought +with it, we may begin to bear still farther onward the banner of +enlightenment--a banner bearing the three names: Petrarch, Erasmus, +Voltaire. We have taken a forward step out of reaction. + +[15] Literally man-feeling or human outlook. + + +27 + +=A Substitute for Religion.=--It is supposed to be a recommendation for +philosophy to say of it that it provides the people with a substitute +for religion. And in fact, the training of the intellect does +necessitate the convenient laying out of the track of thought, since the +transition from religion by way of science entails a powerful, perilous +leap,--something that should be advised against. With this +qualification, the recommendation referred to is a just one. At the same +time, it should be further explained that the needs which religion +satisfies and which science must now satisfy, are not immutable. Even +they can be diminished and uprooted. Think, for instance, of the +christian soul-need, the sighs over one's inner corruption, the anxiety +regarding salvation--all notions that arise simply out of errors of the +reason and require no satisfaction at all, but annihilation. A +philosophy can either so affect these needs as to appease them or else +put them aside altogether, for they are acquired, circumscribed needs, +based upon hypotheses which those of science explode. Here, for the +purpose of affording the means of transition, for the sake of lightening +the spirit overburdened with feeling, art can be employed to far better +purpose, as these hypotheses receive far less support from art than from +a metaphysical philosophy. Then from art it is easier to go over to a +really emancipating philosophical science. + + +28 + +=Discredited Words.=--Away with the disgustingly over-used words +optimism and pessimism! For the occasion for using them grows daily +less; only drivelers now find them indispensably necessary. What earthly +reason could anyone have for being an optimist unless he had a god to +defend who _must_ have created the best of all possible worlds, since he +is himself all goodness and perfection?--but what thinking man has now +any need for the hypothesis that there is a god?--There is also no +occasion whatever for a pessimistic confession of faith, unless one has +a personal interest in denouncing the advocate of god, the theologian or +the theological philosopher, and maintaining the counter proposition +that evil reigns, that wretchedness is more potent than joy, that the +world is a piece of botch work, that phenomenon (Erscheinung) is but the +manifestation of some evil spirit. But who bothers his head about the +theologians any more--except the theologians themselves? Apart from all +theology and its antagonism, it is manifest that the world is neither +good nor bad, (to say nothing about its being the best or the worst) and +that these ideas of "good" and "bad" have significance only in relation +to men, indeed, are without significance at all, in view of the sense in +which they are usually employed. The contemptuous and the eulogistic +point of view must, in every case, be repudiated. + + +29 + +=Intoxicated by the Perfume of Flowers.=--The ship of humanity, it is +thought, acquires an ever deeper draught the more it is laden. It is +believed that the more profoundly man thinks, the more exquisitely he +feels, the higher the standard he sets for himself, the greater his +distance from the other animals--the more he appears as a genius +(Genie) among animals--the nearer he gets to the true nature of the +world and to comprehension thereof: this, indeed, he really does through +science, but he thinks he does it far more adequately through his +religions and arts. These are, certainly, a blossoming of the world, but +not, therefore, _nearer the roots of the world_ than is the stalk. One +cannot learn best from it the nature of the world, although nearly +everyone thinks so. _Error_ has made men so deep, sensitive and +imaginative in order to bring forth such flowers as religions and arts. +Pure apprehension would be unable to do that. Whoever should disclose to +us the essence of the world would be undeceiving us most cruelly. Not +the world as thing-in-itself but the world as idea[16] (as error) is +rich in portent, deep, wonderful, carrying happiness and unhappiness in +its womb. This result leads to a philosophy of world negation: which, at +any rate, can be as well combined with a practical world affirmation as +with its opposite. + +[16] Vorstellung: this word sometimes corresponds to the English word +"idea", at others to "conception" or "notion." + + +30 + +=Evil Habits in Reaching Conclusions.=--The most usual erroneous +conclusions of men are these: a thing[17] exists, therefore it is right: +Here from capacity to live is deduced fitness, from fitness, is deduced +justification. So also: an opinion gives happiness, therefore it is the +true one, its effect is good, therefore it is itself good and true. Here +is predicated of the effect that it gives happiness, that it is good in +the sense of utility, and there is likewise predicated of the cause that +it is good, but good in the sense of logical validity. Conversely, the +proposition would run: a thing[17] cannot attain success, cannot +maintain itself, therefore it is evil: a belief troubles [the believer], +occasions pain, therefore it is false. The free spirit, who is sensible +of the defect in this method of reaching conclusions and has had to +suffer its consequences, often succumbs to the temptation to come to the +very opposite conclusions (which, in general, are, of course, equally +erroneous): a thing cannot maintain itself: therefore it is good; a +belief is troublesome, therefore it is true. + +[17] Sache, thing but not in the sense of Ding. Sache is of very +indefinite application (res). + + +31 + +=The Illogical is Necessary.=--Among the things which can bring a +thinker to distraction is the knowledge that the illogical is necessary +to mankind and that from the illogical springs much that is good. The +illogical is so imbedded in the passions, in language, in art, in +religion and, above all, in everything that imparts value to life that +it cannot be taken away without irreparably injuring those beautiful +things. Only men of the utmost simplicity can believe that the nature +man knows can be changed into a purely logical nature. Yet were there +steps affording approach to this goal, how utterly everything would be +lost on the way! Even the most rational man needs nature again, from +time to time, that is, his illogical fundamental relation +(Grundstellung) to all things. + + +32 + +=Being Unjust is Essential.=--All judgments of the value of life are +illogically developed and therefore unjust. The vice of the judgment +consists, first, in the way in which the subject matter comes under +observation, that is, very incompletely; secondly in the way in which +the total is summed up; and, thirdly, in the fact that each single item +in the totality of the subject matter is itself the result of defective +perception, and this from absolute necessity. No practical knowledge of +a man, for example, stood he never so near to us, can be complete--so +that we could have a logical right to form a total estimate of him; all +estimates are summary and must be so. Then the standard by which we +measure, (our being) is not an immutable quantity; we have moods and +variations, and yet we should know ourselves as an invariable standard +before we undertake to establish the nature of the relation of any thing +(Sache) to ourselves. Perhaps it will follow from all this that one +should form no judgments whatever; if one could but merely _live_ +without having to form estimates, without aversion and without +partiality!--for everything most abhorred is closely connected with an +estimate, as well as every strongest partiality. An inclination towards +a thing, or from a thing, without an accompanying feeling that the +beneficial is desired and the pernicious contemned, an inclination +without a sort of experiential estimation of the desirability of an end, +does not exist in man. We are primordially illogical and hence unjust +beings _and can recognise this fact_: this is one of the greatest and +most baffling discords of existence. + + +33 + +=Error Respecting Living for the Sake of Living Essential.=--Every +belief in the value and worthiness of life rests upon defective +thinking; it is for this reason alone possible that sympathy with the +general life and suffering of mankind is so imperfectly developed in the +individual. Even exceptional men, who can think beyond their own +personalities, do not have this general life in view, but isolated +portions of it. If one is capable of fixing his observation upon +exceptional cases, I mean upon highly endowed individuals and pure +souled beings, if their development is taken as the true end of +world-evolution and if joy be felt in their existence, then it is +possible to believe in the value of life, because in that case the rest +of humanity is overlooked: hence we have here defective thinking. So, +too, it is even if all mankind be taken into consideration, and one +species only of impulses (the less egoistic) brought under review and +those, in consideration of the other impulses, exalted: then something +could still be hoped of mankind in the mass and to that extent there +could exist belief in the value of life: here, again, as a result of +defective thinking. Whatever attitude, thus, one may assume, one is, as +a result of this attitude, an exception among mankind. Now, the great +majority of mankind endure life without any great protest, and believe, +to this extent, in the value of existence, but that is because each +individual decides and determines alone, and never comes out of his own +personality like these exceptions: everything outside of the personal +has no existence for them or at the utmost is observed as but a faint +shadow. Consequently the value of life for the generality of mankind +consists simply in the fact that the individual attaches more importance +to himself than he does to the world. The great lack of imagination from +which he suffers is responsible for his inability to enter into the +feelings of beings other than himself, and hence his sympathy with their +fate and suffering is of the slightest possible description. On the +other hand, whosoever really _could_ sympathise, necessarily doubts the +value of life; were it possible for him to sum up and to feel in himself +the total consciousness of mankind, he would collapse with a malediction +against existence,--for mankind is, in the mass, without a goal, and +hence man cannot find, in the contemplation of his whole course, +anything to serve him as a mainstay and a comfort, but rather a reason +to despair. If he looks beyond the things that immediately engage him to +the final aimlessness of humanity, his own conduct assumes in his eyes +the character of a frittering away. To feel oneself, however, as +humanity (not alone as an individual) frittered away exactly as we see +the stray leaves frittered away by nature, is a feeling transcending all +feeling. But who is capable of it? Only a poet, certainly: and poets +always know how to console themselves. + + +34 + +=For Tranquility.=--But will not our philosophy become thus a tragedy? +Will not truth prove the enemy of life, of betterment? A question seems +to weigh upon our tongue and yet will not put itself into words: whether +one _can_ knowingly remain in the domain of the untruthful? or, if one +_must_, whether, then, death would not be preferable? For there is no +longer any ought (Sollen), morality; so far as it is involved "ought," +is, through our point of view, as utterly annihilated as religion. Our +knowledge can permit only pleasure and pain, benefit and injury, to +subsist as motives. But how can these motives be distinguished from the +desire for truth? Even they rest upon error (in so far, as already +stated, partiality and dislike and their very inaccurate estimates +palpably modify our pleasure and our pain). The whole of human life is +deeply involved in _untruth_. The individual cannot extricate it from +this pit without thereby fundamentally clashing with his whole past, +without finding his present motives of conduct, (as that of honor) +illegitimate, and without opposing scorn and contempt to the ambitions +which prompt one to have regard for the future and for one's happiness +in the future. Is it true, does there, then, remain but one way of +thinking, which, as a personal consequence brings in its train despair, +and as a theoretical [consequence brings in its train] a philosophy of +decay, disintegration, self annihilation? I believe the deciding +influence, as regards the after-effect of knowledge, will be the +_temperament_ of a man; I can, in addition to this after-effect just +mentioned, suppose another, by means of which a much simpler life, and +one freer from disturbances than the present, could be lived; so that at +first the old motives of vehement passion might still have strength, +owing to hereditary habit, but they would gradually grow weaker under +the influence of purifying knowledge. A man would live, at last, both +among men and unto himself, as in the natural state, without praise, +reproach, competition, feasting one's eyes, as if it were a play, upon +much that formerly inspired dread. One would be rid of the strenuous +element, and would no longer feel the goad of the reflection that man is +not even [as much as] nature, nor more than nature. To be sure, this +requires, as already stated, a good temperament, a fortified, gentle and +naturally cheerful soul, a disposition that has no need to be on its +guard against its own eccentricities and sudden outbreaks and that in +its utterances manifests neither sullenness nor a snarling tone--those +familiar, disagreeable characteristics of old dogs and old men that have +been a long time chained up. Rather must a man, from whom the ordinary +bondages of life have fallen away to so great an extent, so do that he +only lives on in order to grow continually in knowledge, and to learn to +resign, without envy and without disappointment, much, yes nearly +everything, that has value in the eyes of men. He must be content with +such a free, fearless soaring above men, manners, laws and traditional +estimates of things, as the most desirable of all situations. He will +freely share the joy of being in such a situation, and he has, perhaps, +nothing else to share--in which renunciation and self-denial really most +consist. But if more is asked of him, he will, with a benevolent shake +of the head, refer to his brother, the free man of fact, and will, +perhaps, not dissemble a little contempt: for, as regards his "freedom," +thereby hangs a tale.[18] + +[18] den mit dessen "Freiheit" hat es eine eigene Bewandtniss. + + + + +HISTORY OF THE MORAL FEELINGS. + + +35 + +=Advantages of Psychological Observation.=--That reflection regarding +the human, all-too-human--or as the learned jargon is: psychological +observation--is among the means whereby the burden of life can be made +lighter, that practice in this art affords presence of mind in difficult +situations and entertainment amid a wearisome environment, aye, that +maxims may be culled in the thorniest and least pleasing paths of life +and invigoration thereby obtained: this much was believed, was known--in +former centuries. Why was this forgotten in our own century, during +which, at least in Germany, yes in Europe, poverty as regards +psychological observation would have been manifest in many ways had +there been anyone to whom this poverty could have manifested itself. Not +only in the novel, in the romance, in philosophical standpoints--these +are the works of exceptional men; still more in the state of opinion +regarding public events and personages; above all in general society, +which says much about men but nothing whatever about man, there is +totally lacking the art of psychological analysis and synthesis. But why +is the richest and most harmless source of entertainment thus allowed to +run to waste? Why is the greatest master of the psychological maxim no +longer read?--for, with no exaggeration whatever be it said: the +educated person in Europe who has read La Rochefoucauld and his +intellectual and artistic affinities is very hard to find; still harder, +the person who knows them and does not disparage them. Apparently, too, +this unusual reader takes far less pleasure in them than the form +adopted by these artists should afford him: for the subtlest mind cannot +adequately appreciate the art of maxim-making unless it has had training +in it, unless it has competed in it. Without such practical +acquaintance, one is apt to look upon this making and forming as a much +easier thing than it really is; one is not keenly enough alive to the +felicity and the charm of success. Hence present day readers of maxims +have but a moderate, tempered pleasure in them, scarcely, indeed, a true +perception of their merit, so that their experiences are about the same +as those of the average beholder of cameos: people who praise because +they cannot appreciate, and are very ready to admire and still readier +to turn away. + + +36 + +=Objection.=--Or is there a counter-proposition to the dictum that +psychological observation is one of the means of consoling, lightening, +charming existence? Have enough of the unpleasant effects of this art +been experienced to justify the person striving for culture in turning +his regard away from it? In all truth, a certain blind faith in the +goodness of human nature, an implanted distaste for any disparagement of +human concerns, a sort of shamefacedness at the nakedness of the soul, +may be far more desirable things in the general happiness of a man, than +this only occasionally advantageous quality of psychological +sharpsightedness; and perhaps belief in the good, in virtuous men and +actions, in a plenitude of disinterested benevolence has been more +productive of good in the world of men in so far as it has made men less +distrustful. If Plutarch's heroes are enthusiastically imitated and a +reluctance is experienced to looking too critically into the motives of +their actions, not the knowledge but the welfare of human society is +promoted thereby: psychological error and above all obtuseness in regard +to it, help human nature forward, whereas knowledge of the truth is more +promoted by means of the stimulating strength of a hypothesis; as La +Rochefoucauld in the first edition of his "Sentences and Moral Maxims" +has expressed it: "What the world calls virtue is ordinarily but a +phantom created by the passions, and to which we give a good name in +order to do whatever we please with impunity." La Rochefoucauld and +those other French masters of soul-searching (to the number of whom has +lately been added a German, the author of "Psychological Observations") +are like expert marksmen who again and again hit the black spot--but it +is the black spot in human nature. Their art inspires amazement, but +finally some spectator, inspired, not by the scientific spirit but by a +humanitarian feeling, execrates an art that seems to implant in the soul +a taste for belittling and impeaching mankind. + + +37 + +=Nevertheless.=--The matter therefore, as regards pro and con, stands +thus: in the present state of philosophy an awakening of the moral +observation is essential. The repulsive aspect of psychological +dissection, with the knife and tweezers entailed by the process, can no +longer be spared humanity. Such is the imperative duty of any science +that investigates the origin and history of the so-called moral feelings +and which, in its progress, is called upon to posit and to solve +advanced social problems:--The older philosophy does not recognize the +newer at all and, through paltry evasions, has always gone astray in the +investigation of the origin and history of human estimates +(Werthschätzungen). With what results may now be very clearly perceived, +since it has been shown by many examples, how the errors of the greatest +philosophers have their origin in a false explanation of certain human +actions and feelings; how upon the foundation of an erroneous analysis +(for example, of the so called disinterested actions), a false ethic is +reared, to support which religion and like mythological monstrosities +are called in, until finally the shades of these troubled spirits +collapse in physics and in the comprehensive world point of view. But if +it be established that superficiality of psychological observation has +heretofore set the most dangerous snares for human judgment and +deduction, and will continue to do so, all the greater need is there of +that steady continuance of labor that never wearies putting stone upon +stone, little stone upon little stone; all the greater need is there of +a courage that is not ashamed of such humble labor and that will oppose +persistence, to all contempt. It is, finally, also true that countless +single observations concerning the human, all-too-human, have been +first made and uttered in circles accustomed, not to furnish matter for +scientific knowledge, but for intellectual pleasure-seeking; and the +original home atmosphere--a very seductive atmosphere--of the moral +maxim has almost inextricably interpenetrated the entire species, so +that the scientific man involuntarily manifests a sort of mistrust of +this species and of its seriousness. But it is sufficient to point to +the consequences: for already it is becoming evident that events of the +most portentous nature are developing in the domain of psychological +observation. What is the leading conclusion arrived at by one of the +subtlest and calmest of thinkers, the author of the work "Concerning the +Origin of the Moral Feelings", as a result of his thorough and incisive +analysis of human conduct? "The moral man," he says, "stands no nearer +the knowable (metaphysical) world than the physical man."[19] This +dictum, grown hard and cutting beneath the hammer-blow of historical +knowledge, can some day, perhaps, in some future or other, serve as the +axe that will be laid to the root of the "metaphysical necessities" of +men--whether more to the blessing than to the banning of universal well +being who can say?--but in any event a dictum fraught with the most +momentous consequences, fruitful and fearful at once, and confronting +the world in the two faced way characteristic of all great facts. + +[19] "Der moralische Mensch, sagt er, steht der intelligiblen +(metaphysischen) Welt nicht näher, als der physische Mensch." + + +38 + +=To What Extent Useful.=--Therefore, whether psychological observation +is more an advantage than a disadvantage to mankind may always remain +undetermined: but there is no doubt that it is necessary, because +science can no longer dispense with it. Science, however, recognizes no +considerations of ultimate goals or ends any more than nature does; but +as the latter duly matures things of the highest fitness for certain +ends without any intention of doing it, so will true science, doing with +ideas what nature does with matter,[20] promote the purposes and the +welfare of humanity, (as occasion may afford, and in many ways) and +attain fitness [to ends]--but likewise without having intended it. + +[20] als die Nachahmung der Natur in Begriffen, literally: "as the +counterfeit of nature in (regard to) ideas." + +He to whom the atmospheric conditions of such a prospect are too wintry, +has too little fire in him: let him look about him, and he will become +sensible of maladies requiring an icy air, and of people who are so +"kneaded together" out of ardor and intellect that they can scarcely +find anywhere an atmosphere too cold and cutting for them. Moreover: as +too serious individuals and nations stand in need of trivial +relaxations; as others, too volatile and excitable require onerous, +weighty ordeals to render them entirely healthy: should not we, the more +intellectual men of this age, which is swept more and more by +conflagrations, catch up every cooling and extinguishing appliance we +can find that we may always remain as self contained, steady and calm as +we are now, and thereby perhaps serve this age as its mirror and self +reflector, when the occasion arises? + + +39 + +=The Fable of Discretionary Freedom.=--The history of the feelings, on +the basis of which we make everyone responsible, hence, the so-called +moral feelings, is traceable in the following leading phases. At first +single actions are termed good or bad without any reference to their +motive, but solely because of the utilitarian or prejudicial +consequences they have for the community. In time, however, the origin +of these designations is forgotten [but] it is imagined that action in +itself, without reference to its consequences, contains the property +"good" or "bad": with the same error according to which language +designates the stone itself as hard[ness] the tree itself as +green[ness]--for the reason, therefore, that what is a consequence is +comprehended as a cause. Accordingly, the good[ness] or bad[ness] is +incorporated into the motive and [any] deed by itself is regarded as +morally ambiguous. A step further is taken, and the predication good or +bad is no longer made of the particular motives but of the entire nature +of a man, out of which motive grows as grow the plants out of the soil. +Thus man is successively made responsible for his [particular] acts, +then for his [course of] conduct, then for his motives and finally for +his nature. Now, at last, is it discovered that this nature, even, +cannot be responsible, inasmuch as it is only and wholly a necessary +consequence and is synthesised out of the elements and influence of past +and present things: therefore, that man is to be made responsible for +nothing, neither for his nature, nor his motives, nor his [course of] +conduct nor his [particular] acts. By this [process] is gained the +knowledge that the history of moral estimates is the history of error, +of the error of responsibility: as is whatever rests upon the error of +the freedom of the will. Schopenhauer concluded just the other way, +thus: since certain actions bring depression ("consciousness of guilt") +in their train, there must, then, exist responsibility, for there would +be no basis for this depression at hand if all man's affairs did not +follow their course of necessity--as they do, indeed, according to the +opinion of this philosopher, follow their course--but man himself, +subject to the same necessity, would be just the man that he is--which +Schopenhauer denies. From the fact of such depression Schopenhauer +believes himself able to prove a freedom which man in some way must have +had, not indeed in regard to his actions but in regard to his nature: +freedom, therefore, to be thus and so, not to act thus and so. Out of +the _esse_, the sphere of freedom and responsibility, follows, according +to his opinion, the _operari_, the spheres of invariable causation, +necessity and irresponsibility. This depression, indeed, is due +apparently to the _operari_--in so far as it be delusive--but in truth +to whatever _esse_ be the deed of a free will, the basic cause of the +existence of an individual: [in order to] let man become whatever he +wills to become, his [to] will (Wollen) must precede his +existence.--Here, apart from the absurdity of the statement just made, +there is drawn the wrong inference that the fact of the depression +explains its character, the rational admissibility of it: from such a +wrong inference does Schopenhauer first come to his fantastic consequent +of the so called discretionary freedom (intelligibeln Freiheit). (For +the origin of this fabulous entity Plato and Kant are equally +responsible). But depression after the act does not need to be rational: +indeed, it is certainly not so at all, for it rests upon the erroneous +assumption that the act need not necessarily have come to pass. +Therefore: only because man deems himself free, but not because +he is free, does he experience remorse and the stings of +conscience.--Moreover, this depression is something that can be grown +out of; in many men it is not present at all as a consequence of acts +which inspire it in many other men. It is a very varying thing and one +closely connected with the development of custom and civilization, and +perhaps manifest only during a relatively brief period of the world's +history.--No one is responsible for his acts, no one for his nature; to +judge is tantamount to being unjust. This applies as well when the +individual judges himself. The proposition is as clear as sunlight, and +yet here everyone prefers to go back to darkness and untruth: for fear +of the consequences. + + +40 + +=Above Animal.=--The beast in us must be wheedled: ethic is necessary, +that we may not be torn to pieces. Without the errors involved in the +assumptions of ethics, man would have remained an animal. Thus has he +taken himself as something higher and imposed rigid laws upon himself. +He feels hatred, consequently, for states approximating the animal: +whence the former contempt for the slave as a not-yet-man, as a thing, +is to be explained. + + +41 + +=Unalterable Character.=--That character is unalterable is not, in the +strict sense, true; rather is this favorite proposition valid only to +the extent that during the brief life period of a man the potent new +motives can not, usually, press down hard enough to obliterate the lines +imprinted by ages. Could we conceive of a man eighty thousand years old, +we should have in him an absolutely alterable character; so that the +maturities of successive, varying individuals would develop in him. The +shortness of human life leads to many erroneous assertions concerning +the qualities of man. + + +42 + +=Classification of Enjoyments and Ethic.=--The once accepted comparative +classification of enjoyments, according to which an inferior, higher, +highest egoism may crave one or another enjoyment, now decides as to +ethical status or unethical status. A lower enjoyment (for example, +sensual pleasure) preferred to a more highly esteemed one (for example, +health) rates as unethical, as does welfare preferred to freedom. The +comparative classification of enjoyments is not, however, alike or the +same at all periods; when anyone demands satisfaction of the law, he is, +from the point of view of an earlier civilization, moral, from that of +the present, non-moral. "Unethical" indicates, therefore, that a man is +not sufficiently sensible to the higher, finer impulses which the +present civilization has brought with it, or is not sensible to them at +all; it indicates backwardness, but only from the point of view of the +contemporary degree of distinction.--The comparative classification of +enjoyments itself is not determined according to absolute ethics; but +after each new ethical adjustment, it is then decided whether conduct be +ethical or the reverse. + + +43 + +=Inhuman Men as Survivals.=--Men who are now inhuman must serve us as +surviving specimens of earlier civilizations. The mountain height of +humanity here reveals its lower formations, which might otherwise remain +hidden from view. There are surviving specimens of humanity whose brains +through the vicissitudes of heredity, have escaped proper development. +They show us what we all were and thus appal us; but they are as little +responsible on this account as is a piece of granite for being granite. +In our own brains there must be courses and windings corresponding to +such characters, just as in the forms of some human organs there survive +traces of fishhood. But these courses and windings are no longer the bed +in which flows the stream of our feeling. + + +44 + +=Gratitude and Revenge.=--The reason the powerful man is grateful is +this. His benefactor has, through his benefaction, invaded the domain of +the powerful man and established himself on an equal footing: the +powerful man in turn invades the domain of the benefactor and gets +satisfaction through the act of gratitude. It is a mild form of revenge. +By not obtaining the satisfaction of gratitude the powerful would have +shown himself powerless and have ranked as such thenceforward. Hence +every society of the good, that is to say, of the powerful originally, +places gratitude among the first of duties.--Swift has added the dictum +that man is grateful in the same degree that he is revengeful. + + +45 + +=Two-fold Historical Origin of Good and Evil.=--The notion of good and +bad has a two-fold historical origin: namely, first, in the spirit of +ruling races and castes. Whoever has power to requite good with good and +evil with evil and actually brings requital, (that is, is grateful and +revengeful) acquires the name of being good; whoever is powerless and +cannot requite is called bad. A man belongs, as a good individual, to +the "good" of a community, who have a feeling in common, because all the +individuals are allied with one another through the requiting sentiment. +A man belongs, as a bad individual, to the "bad," to a mass of +subjugated, powerless men who have no feeling in common. The good are a +caste, the bad are a quantity, like dust. Good and bad is, for a +considerable period, tantamount to noble and servile, master and slave. +On the other hand an enemy is not looked upon as bad: he can requite. +The Trojan and the Greek are in Homer both good. Not he, who does no +harm, but he who is despised, is deemed bad. In the community of the +good individuals [the quality of] good[ness] is inherited; it is +impossible for a bad individual to grow from such a rich soil. If, +notwithstanding, one of the good individuals does something unworthy of +his goodness, recourse is had to exorcism; thus the guilt is ascribed to +a deity, the while it is declared that this deity bewitched the good man +into madness and blindness.--Second, in the spirit of the subjugated, +the powerless. Here every other man is, to the individual, hostile, +inconsiderate, greedy, inhuman, avaricious, be he noble or servile; bad +is the characteristic term for man, for every living being, indeed, that +is recognized at all, even for a god: human, divine, these notions are +tantamount to devilish, bad. Manifestations of goodness, sympathy, +helpfulness, are regarded with anxiety as trickiness, preludes to an +evil end, deception, subtlety, in short, as refined badness. With such a +predisposition in individuals, a feeling in common can scarcely arise at +all, at most only the rudest form of it: so that everywhere that this +conception of good and evil prevails, the destruction of the +individuals, their race and nation, is imminent.--Our existing morality +has developed upon the foundation laid by ruling races and castes. + + +46 + +=Sympathy Greater than Suffering.=--There are circumstances in which +sympathy is stronger than the suffering itself. We feel more pain, for +instance, when one of our friends becomes guilty of a reprehensible +action than if we had done the deed ourselves. We once, that is, had +more faith in the purity of his character than he had himself. Hence our +love for him, (apparently because of this very faith) is stronger than +is his own love for himself. If, indeed, his egoism really suffers more, +as a result, than our egoism, inasmuch as he must take the consequences +of his fault to a greater extent than ourselves, nevertheless, the +unegoistic--this word is not to be taken too strictly, but simply as a +modified form of expression--in us is more affected by his guilt than +the unegoistic in him. + + +47 + +=Hypochondria.=--There are people who, from sympathy and anxiety for +others become hypochondriacal. The resulting form of compassion is +nothing else than sickness. So, also, is there a Christian hypochondria, +from which those singular, religiously agitated people suffer who place +always before their eyes the suffering and death of Christ. + + +48 + +=Economy of Blessings.=--The advantageous and the pleasing, as the +healthiest growths and powers in the intercourse of men, are such +precious treasures that it is much to be wished the use made of these +balsamic means were as economical as possible: but this is impossible. +Economy in the use of blessings is the dream of the craziest of +Utopians. + + +49 + +=Well-Wishing.=--Among the small, but infinitely plentiful and therefore +very potent things to which science must pay more attention than to the +great, uncommon things, well-wishing[21] must be reckoned; I mean those +manifestations of friendly disposition in intercourse, that laughter of +the eye, every hand pressure, every courtesy from which, in general, +every human act gets its quality. Every teacher, every functionary adds +this element as a gratuity to whatever he does as a duty; it is the +perpetual well spring of humanity, like the waves of light in which +everything grows; thus, in the narrowest circles, within the family, +life blooms and flowers only through this kind feeling. The +cheerfulness, friendliness and kindness of a heart are unfailing +sources of unegoistic impulse and have made far more for civilization +than those other more noised manifestations of it that are styled +sympathy, benevolence and sacrifice. But it is customary to depreciate +these little tokens of kindly feeling, and, indeed, there is not much of +the unegoistic in them. The sum of these little doses is very great, +nevertheless; their combined strength is of the greatest of +strengths.--Thus, too, much more happiness is to be found in the world +than gloomy eyes discover: that is, if the calculation be just, and all +these pleasing moments in which every day, even the meanest human life, +is rich, be not forgotten. + +[21] Wohl-wollen, kind feeling. It stands here for benevolence but not +benevolence in the restricted sense of the word now prevailing. + + +50 + +=The Desire to Inspire Compassion.=--La Rochefoucauld, in the most +notable part of his self portraiture (first printed 1658) reaches the +vital spot of truth when he warns all those endowed with reason to be on +their guard against compassion, when he advises that this sentiment be +left to men of the masses who stand in need of the promptings of the +emotions (since they are not guided by reason) to induce them to give +aid to the suffering and to be of service in misfortune: whereas +compassion, in his (and Plato's) view, deprives the heart of strength. +To be sure, sympathy should be manifested but men should take care not +to feel it; for the unfortunate are rendered so dull that the +manifestation of sympathy affords them the greatest happiness in the +world.--Perhaps a more effectual warning against this compassion can be +given if this need of the unfortunate be considered not simply as +stupidity and intellectual weakness, not as a sort of distraction of the +spirit entailed by misfortune itself (and thus, indeed, does La +Rochefoucauld seem to view it) but as something quite different and more +momentous. Let note be taken of children who cry and scream in order to +be compassionated and who, therefore, await the moment when their +condition will be observed; come into contact with the sick and the +oppressed in spirit and try to ascertain if the wailing and sighing, the +posturing and posing of misfortune do not have as end and aim the +causing of pain to the beholder: the sympathy which each beholder +manifests is a consolation to the weak and suffering only in as much as +they are made to perceive that at least they have the power, +notwithstanding all their weakness, to inflict pain. The unfortunate +experiences a species of joy in the sense of superiority which the +manifestation of sympathy entails; his imagination is exalted; he is +always strong enough, then, to cause the world pain. Thus is the thirst +for sympathy a thirst for self enjoyment and at the expense of one's +fellow creatures: it shows man in the whole ruthlessness of his own dear +self: not in his mere "dullness" as La Rochefoucauld thinks.--In social +conversation three fourths of all the questions are asked, and three +fourths of all the replies are made in order to inflict some little +pain; that is why so many people crave social intercourse: it gives them +a sense of their power. In these countless but very small doses in which +the quality of badness is administered it proves a potent stimulant of +life: to the same extent that well wishing--(Wohl-wollen) distributed +through the world in like manner, is one of the ever ready +restoratives.--But will many honorable people be found to admit that +there is any pleasure in administering pain? that entertainment--and +rare entertainment--is not seldom found in causing others, at least in +thought, some pain, and in raking them with the small shot of +wickedness? The majority are too ignoble and a few are too good to know +anything of this pudendum: the latter may, consequently, be prompt to +deny that Prosper Mérimée is right when he says: "Know, also, that +nothing is more common than to do wrong for the pleasure of doing it." + + +51 + +=How Appearance Becomes Reality.=--The actor cannot, at last, refrain, +even in moments of the deepest pain, from thinking of the effect +produced by his deportment and by his surroundings--for example, even at +the funeral of his own child: he will weep at his own sorrow and its +manifestations as though he were his own audience. The hypocrite who +always plays one and the same part, finally ceases to be a hypocrite; as +in the case of priests who, when young men, are always, either +consciously or unconsciously, hypocrites, and finally become naturally +and then really, without affectation, mere priests: or if the father +does not carry it to this extent, the son, who inherits his father's +calling and gets the advantage of the paternal progress, does. When +anyone, during a long period, and persistently, wishes to appear +something, it will at last prove difficult for him to be anything else. +The calling of almost every man, even of the artist, begins with +hypocrisy, with an imitation of deportment, with a copying of the +effective in manner. He who always wears the mask of a friendly man must +at last gain a power over friendliness of disposition, without which the +expression itself of friendliness is not to be gained--and finally +friendliness of disposition gains the ascendancy over him--he _is_ +benevolent. + + +52 + +=The Point of Honor in Deception.=--In all great deceivers one +characteristic is prominent, to which they owe their power. In the very +act of deception, amid all the accompaniments, the agitation in the +voice, the expression, the bearing, in the crisis of the scene, there +comes over them a belief in themselves; this it is that acts so +effectively and irresistibly upon the beholders. Founders of religions +differ from such great deceivers in that they never come out of this +state of self deception, or else they have, very rarely, a few moments +of enlightenment in which they are overcome by doubt; generally, +however, they soothe themselves by ascribing such moments of +enlightenment to the evil adversary. Self deception must exist that both +classes of deceivers may attain far reaching results. For men believe in +the truth of all that is manifestly believed with due implicitness by +others. + + +53 + +=Presumed Degrees of Truth.=--One of the most usual errors of deduction +is: because someone truly and openly is against us, therefore he speaks +the truth. Hence the child has faith in the judgments of its elders, the +Christian in the assertions of the founder of the church. So, too, it +will not be admitted that all for which men sacrificed life and +happiness in former centuries was nothing but delusion: perhaps it is +alleged these things were degrees of truth. But what is really meant is +that, if a person sincerely believes a thing and has fought and died for +his faith, it would be too _unjust_ if only delusion had inspired him. +Such a state of affairs seems to contradict eternal justice. For that +reason the heart of a sensitive man pronounces against his head the +judgment: between moral conduct and intellectual insight there must +always exist an inherent connection. It is, unfortunately, otherwise: +for there is no eternal justice. + + +54 + +=Falsehood.=--Why do men, as a rule, speak the truth in the ordinary +affairs of life? Certainly not for the reason that a god has forbidden +lying. But because first: it is more convenient, as falsehood entails +invention, make-believe and recollection (wherefore Swift says that +whoever invents a lie seldom realises the heavy burden he takes up: he +must, namely, for every lie that he tells, insert twenty more). +Therefore, because in plain ordinary relations of life it is expedient +to say without circumlocution: I want this, I have done this, and the +like; therefore, because the way of freedom and certainty is surer than +that of ruse.--But if it happens that a child is brought up in sinister +domestic circumstances, it will then indulge in falsehood as matter of +course, and involuntarily say anything its own interests may prompt: an +inclination for truth, an aversion to falsehood, is quite foreign and +uncongenial to it, and hence it lies in all innocence. + + +55 + +=Ethic Discredited for Faith's Sake.=--No power can sustain itself when +it is represented by mere humbugs: the Catholic Church may possess ever +so many "worldly" sources of strength, but its true might is comprised +in those still numberless priestly natures who make their lives stern +and strenuous and whose looks and emaciated bodies are eloquent of night +vigils, fasts, ardent prayer, perhaps even of whip lashes: these things +make men tremble and cause them anxiety: what, if it be really +imperative to live thus? This is the dreadful question which their +aspect occasions. As they spread this doubt, they lay anew the prop of +their power: even the free thinkers dare not oppose such +disinterestedness with severe truth and cry: "Thou deceived one, +deceive not!"--Only the difference of standpoint separates them from +him: no difference in goodness or badness. But things we cannot +accomplish ourselves, we are apt to criticise unfairly. Thus we are told +of the cunning and perverted acts of the Jesuits, but we overlook the +self mastery that each Jesuit imposes upon himself and also the fact +that the easy life which the Jesuit manuals advocate is for the benefit, +not of the Jesuits but the laity. Indeed, it may be questioned whether +we enlightened ones would become equally competent workers as the result +of similar tactics and organization, and equally worthy of admiration as +the result of self mastery, indefatigable industry and devotion. + + +56 + +=Victory of Knowledge over Radical Evil.=--It proves a material gain to +him who would attain knowledge to have had during a considerable period +the idea that mankind is a radically bad and perverted thing: it is a +false idea, as is its opposite, but it long held sway and its roots have +reached down even to ourselves and our present world. In order to +understand _ourselves_ we must understand _it_; but in order to attain a +loftier height we must step above it. We then perceive that there is no +such thing as sin in the metaphysical sense: but also, in the same +sense, no such thing as virtue; that this whole domain of ethical +notions is one of constant variation; that there are higher and deeper +conceptions of good and evil, moral and immoral. Whoever desires no more +of things than knowledge of them attains speedily to peace of mind and +will at most err through lack of knowledge, but scarcely through +eagerness for knowledge (or through sin, as the world calls it). He will +not ask that eagerness for knowledge be interdicted and rooted out; but +his single, all powerful ambition to _know_ as thoroughly and as fully +as possible, will soothe him and moderate all that is strenuous in his +circumstances. Moreover, he is now rid of a number of disturbing +notions; he is no longer beguiled by such words as hell-pain, +sinfulness, unworthiness: he sees in them merely the flitting shadow +pictures of false views of life and of the world. + + +57 + +=Ethic as Man's Self-Analysis.=--A good author, whose heart is really in +his work, wishes that someone would arise and wholly refute him if only +thereby his subject be wholly clarified and made plain. The maid in love +wishes that she could attest the fidelity of her own passion through +the faithlessness of her beloved. The soldier wishes to sacrifice his +life on the field of his fatherland's victory: for in the victory of his +fatherland his highest end is attained. The mother gives her child what +she deprives herself of--sleep, the best nourishment and, in certain +circumstances, her health, her self.--But are all these acts unegoistic? +Are these moral deeds miracles because they are, in Schopenhauer's +phrase "impossible and yet accomplished"? Is it not evident that in all +four cases man loves one part of himself, (a thought, a longing, an +experience) more than he loves another part of himself? that he thus +analyses his being and sacrifices one part of it to another part? Is +this essentially different from the behavior of the obstinate man who +says "I would rather be shot than go a step out of my way for this +fellow"?--Preference for something (wish, impulse, longing) is present +in all four instances: to yield to it, with all its consequences, is not +"unegoistic."--In the domain of the ethical man conducts himself not as +individuum but as dividuum. + + +58 + +=What Can be Promised.=--Actions can be promised, but not feelings, for +these are involuntary. Whoever promises somebody to love him always, or +to hate him always, or to be ever true to him, promises something that +it is out of his power to bestow. But he really can promise such courses +of conduct as are the ordinary accompaniments of love, of hate, of +fidelity, but which may also have their source in motives quite +different: for various ways and motives lead to the same conduct. The +promise to love someone always, means, consequently: as long as I love +you, I will manifest the deportment of love; but if I cease to love you +my deportment, although from some other motive, will be just the same, +so that to the people about us it will seem as if my love remained +unchanged.--Hence it is the continuance of the deportment of love that +is promised in every instance in which eternal love (provided no element +of self deception be involved) is sworn. + + +59 + +=Intellect and Ethic.=--One must have a good memory to be able to keep +the promises one makes. One must have a strong imagination in order to +feel sympathy. So closely is ethics connected with intellectual +capacity. + + +60 + +=Desire for Vengeance and Vengeance Itself.=--To meditate revenge and +attain it is tantamount to an attack of fever, that passes away: but to +meditate revenge without possessing the strength or courage to attain it +is tantamount to suffering from a chronic malady, or poisoning of body +and soul. Ethics, which takes only the motive into account, rates both +cases alike: people generally estimate the first case as the worst +(because of the consequences which the deed of vengeance may entail). +Both views are short sighted. + + +61 + +=Ability to Wait.=--Ability to wait is so hard to acquire that great +poets have not disdained to make inability to wait the central motive of +their poems. So Shakespeare in Othello, Sophocles in Ajax, whose suicide +would not have seemed to him so imperative had he only been able to cool +his ardor for a day, as the oracle foreboded: apparently he would then +have repulsed somewhat the fearful whispers of distracted thought and +have said to himself: Who has not already, in my situation, mistaken a +sheep for a hero? is it so extraordinary a thing? On the contrary it is +something universally human: Ajax should thus have soothed himself. +Passion will not wait: the tragic element in the lives of great men does +not generally consist in their conflict with time and the inferiority +of their fellowmen but in their inability to put off their work a year +or two: they cannot wait.--In all duels, the friends who advise have but +to ascertain if the principals can wait: if this be not possible, a duel +is rational inasmuch as each of the combatants may say: "either I +continue to live and the other dies instantly, or vice versa." To wait +in such circumstances would be equivalent to the frightful martyrdom of +enduring dishonor in the presence of him responsible for the dishonor: +and this can easily cost more anguish than life is worth. + + +62 + +=Glutting Revenge.=--Coarse men, who feel a sense of injury, are in the +habit of rating the extent of their injury as high as possible and of +stating the occasion of it in greatly exaggerated language, in order to +be able to feast themselves on the sentiments of hatred and revenge thus +aroused. + + +63 + +=Value of Disparagement.=--Not a few, perhaps the majority of men, find +it necessary, in order to retain their self esteem and a certain +uprightness in conduct, to mentally disparage and belittle all the +people they know. But as the inferior natures are in the majority and as +a great deal depends upon whether they retain or lose this uprightness, +so-- + + +64 + +=The Man in a Rage.=--We should be on our guard against the man who is +enraged against us, as against one who has attempted our life, for the +fact that we still live consists solely in the inability to kill: were +looks sufficient, it would have been all up with us long since. To +reduce anyone to silence by physical manifestations of savagery or by a +terrorizing process is a relic of under civilization. So, too, that cold +look which great personages cast upon their servitors is a remnant of +the caste distinction between man and man; a specimen of rude antiquity: +women, the conservers of the old, have maintained this survival, too, +more perfectly than men. + + +65 + +=Whither Honesty May Lead.=--Someone once had the bad habit of +expressing himself upon occasion, and with perfect honesty, on the +subject of the motives of his conduct, which were as good or as bad as +the motives of all men. He aroused first disfavor, then suspicion, +became gradually of ill repute and was pronounced a person of whom +society should beware, until at last the law took note of such a +perverted being for reasons which usually have no weight with it or to +which it closes its eyes. Lack of taciturnity concerning what is +universally held secret, and an irresponsible predisposition to see what +no one wants to see--oneself--brought him to prison and to early death. + + +66 + +=Punishable, not Punished.=--Our crime against criminals consists in the +fact that we treat them as rascals. + + +67 + +=Sancta simplicitas of Virtue.=--Every virtue has its privilege: for +example, that of contributing its own little bundle of wood to the +funeral pyre of one condemned. + + +68 + +=Morality and Consequence.=--Not alone the beholders of an act generally +estimate the ethical or unethical element in it by the result: no, the +one who performed the act does the same. For the motives and the +intentions are seldom sufficiently apparent, and amid them the memory +itself seems to become clouded by the results of the act, so that a man +often ascribes the wrong motives to his acts or regards the remote +motives as the direct ones. Success often imparts to an action all the +brilliance and honor of good intention, while failure throws the shadow +of conscience over the most estimable deeds. Hence arises the familiar +maxim of the politician: "Give me only success: with it I can win all +the noble souls over to my side--and make myself noble even in my own +eyes."--In like manner will success prove an excellent substitute for a +better argument. To this very day many well educated men think the +triumph of Christianity over Greek philosophy is a proof of the superior +truth of the former--although in this case it was simply the coarser and +more powerful that triumphed over the more delicate and intellectual. As +regards superiority of truth, it is evident that because of it the +reviving sciences have connected themselves, point for point, with the +philosophy of Epicurus, while Christianity has, point for point, +recoiled from it. + + +69 + +=Love and Justice.=--Why is love so highly prized at the expense of +justice and why are such beautiful things spoken of the former as if it +were a far higher entity than the latter? Is the former not palpably a +far more stupid thing than the latter?--Certainly, and on that very +account so much the more agreeable to everybody: it is blind and has a +rich horn of plenty out of which it distributes its gifts to everyone, +even when they are unmerited, even when no thanks are returned. It is +impartial like the rain, which according to the bible and experience, +wets not alone the unjust but, in certain circumstances, the just as +well, and to their skins at that. + + +70 + +=Execution.=--How comes it that every execution causes us more pain than +a murder? It is the coolness of the executioner, the painful +preparation, the perception that here a man is being used as an +instrument for the intimidation of others. For the guilt is not punished +even if there be any: this is ascribable to the teachers, the parents, +the environment, in ourselves, not in the murderer--I mean the +predisposing circumstances. + + +71 + +=Hope.=--Pandora brought the box containing evils and opened it. It was +the gift of the gods to men, a gift of most enticing appearance +externally and called the "box of happiness." Thereupon all the evils, +(living, moving things) flew out: from that time to the present they fly +about and do ill to men by day and night. One evil only did not fly out +of the box: Pandora shut the lid at the behest of Zeus and it remained +inside. Now man has this box of happiness perpetually in the house and +congratulates himself upon the treasure inside of it; it is at his +service: he grasps it whenever he is so disposed, for he knows not that +the box which Pandora brought was a box of evils. Hence he looks upon +the one evil still remaining as the greatest source of happiness--it is +hope.--Zeus intended that man, notwithstanding the evils oppressing him, +should continue to live and not rid himself of life, but keep on making +himself miserable. For this purpose he bestowed hope upon man: it is, in +truth, the greatest of evils for it lengthens the ordeal of man. + + +72 + +=Degree of Moral Susceptibility Unknown.=--The fact that one has or has +not had certain profoundly moving impressions and insights into +things--for example, an unjustly executed, slain or martyred father, a +faithless wife, a shattering, serious accident,--is the factor upon +which the excitation of our passions to white heat principally depends, +as well as the course of our whole lives. No one knows to what lengths +circumstances (sympathy, emotion) may lead him. He does not know the +full extent of his own susceptibility. Wretched environment makes him +wretched. It is as a rule not the quality of our experience but its +quantity upon which depends the development of our superiority or +inferiority, from the point of view of good and evil. + + +73 + +=The Martyr Against His Will.=--In a certain movement there was a man +who was too cowardly and vacillating ever to contradict his comrades. He +was made use of in each emergency, every sacrifice was demanded of him +because he feared the disfavor of his comrades more than he feared +death: he was a petty, abject spirit. They perceived this and upon the +foundation of the qualities just mentioned they elevated him to the +altitude of a hero, and finally even of a martyr. Although the cowardly +creature always inwardly said No, he always said Yes with his lips, even +upon the scaffold, where he died for the tenets of his party: for beside +him stood one of his old associates who so domineered him with look and +word that he actually went to his death with the utmost fortitude and +has ever since been celebrated as a martyr and exalted character. + + +74 + +=General Standard.=--One will rarely err if extreme actions be ascribed +to vanity, ordinary actions to habit and mean actions to fear. + + +75 + +=Misunderstanding of Virtue.=--Whoever has obtained his experience of +vice in connection with pleasure as in the case of one with a youth of +wild oats behind him, comes to the conclusion that virtue must be +connected with self denial. Whoever, on the other hand, has been very +much plagued by his passions and vices, longs to find in virtue the rest +and peace of the soul. That is why it is possible for two virtuous +people to misunderstand one another wholly. + + +76 + +=The Ascetic.=--The ascetic makes out of virtue a slavery. + + +77 + +=Honor Transferred from Persons to Things.=--Actions prompted by love or +by the spirit of self sacrifice for others are universally honored +wherever they are manifest. Hence is magnified the value set upon +whatever things may be loved or whatever things conduce to self +sacrifice: although in themselves they may be worth nothing much. A +valiant army is evidence of the value of the thing it fights for. + + +78 + +=Ambition a Substitute for Moral Feeling.=--Moral feeling should never +become extinct in natures that are destitute of ambition. The ambitious +can get along without moral feeling just as well as with it.--Hence the +sons of retired, ambitionless families, generally become by a series of +rapid gradations, when they lose moral feeling, the most absolute +lunkheads. + + +79 + +=Vanity Enriches.=--How poor the human mind would be without vanity! As +it is, it resembles a well stacked and ever renewed ware-emporium that +attracts buyers of every class: they can find almost everything, have +almost everything, provided they bring with them the right kind of +money--admiration. + + +80 + +=Senility and Death.=--Apart from the demands made by religion, it may +well be asked why it is more honorable in an aged man, who feels the +decline of his powers, to await slow extinction than to fix a term to +his existence himself? Suicide in such a case is a quite natural and due +proceeding that ought to command respect as a triumph of reason: and did +in fact command respect during the times of the masters of Greek +philosophy and the bravest Roman patriots, who usually died by their own +hand. Eagerness, on the other hand, to keep alive from day to day with +the anxious counsel of physicians, without capacity to attain any nearer +to one's ideal of life, is far less worthy of respect.--Religions are +very rich in refuges from the mandate of suicide: hence they ingratiate +themselves with those who cling to life. + + +81 + +=Delusions Regarding Victim and Regarding Evil Doer.=--When the rich man +takes a possession away from the poor man (for example, a prince who +deprives a plebeian of his beloved) there arises in the mind of the poor +man a delusion: he thinks the rich man must be wholly perverted to take +from him the little that he has. But the rich man appreciates the value +of a single possession much less because he is accustomed to many +possessions, so that he cannot put himself in the place of the poor man +and does not act by any means as ill as the latter supposes. Both have a +totally false idea of each other. The iniquities of the mighty which +bulk most largely in history are not nearly so monstrous as they seem. +The hereditary consciousness of being a superior being with superior +environment renders one very callous and lulls the conscience to rest. +We all feel, when the difference between ourselves and some other being +is exceedingly great, that no element of injustice can be involved, and +we kill a fly with no qualms of conscience whatever. So, too, it is no +indication of wickedness in Xerxes (whom even the Greeks represent as +exceptionally noble) that he deprived a father of his son and had him +drawn and quartered because the latter had manifested a troublesome, +ominous distrust of an entire expedition: the individual was in this +case brushed aside as a pestiferous insect. He was too low and mean to +justify continued sentiments of compunction in the ruler of the world. +Indeed no cruel man is ever as cruel, in the main, as his victim thinks. +The idea of pain is never the same as the sensation. The rule is +precisely analogous in the case of the unjust judge, and of the +journalist who by means of devious rhetorical methods, leads public +opinion astray. Cause and effect are in all these instances entwined +with totally different series of feeling and thoughts, whereas it is +unconsciously assumed that principal and victim feel and think exactly +alike, and because of this assumption the guilt of the one is based upon +the pain of the other. + + +82 + +=The Soul's Skin.=--As the bones, flesh, entrails and blood vessels are +enclosed by a skin that renders the aspect of men endurable, so the +impulses and passions of the soul are enclosed by vanity: it is the skin +of the soul. + + +83 + +=Sleep of Virtue.=--If virtue goes to sleep, it will be more vigorous +when it awakes. + + +84 + +=Subtlety of Shame.=--Men are not ashamed of obscene thoughts, but they +are ashamed when they suspect that obscene thoughts are attributed to +them. + + +85 + +=Naughtiness Is Rare.=--Most people are too much absorbed in themselves +to be bad. + + +86 + +=The Mite in the Balance.=--We are praised or blamed, as the one or the +other may be expedient, for displaying to advantage our power of +discernment. + + +87 + +=Luke 18:14 Improved.=--He that humbleth himself wisheth to be exalted. + + +88 + +=Prevention of Suicide.=--There is a justice according to which we may +deprive a man of life, but none that permits us to deprive him of death: +this is merely cruelty. + + +89 + +=Vanity.=--We set store by the good opinion of men, first because it is +of use to us and next because we wish to give them pleasure (children +their parents, pupils their teacher, and well disposed persons all +others generally). Only when the good opinion of men is important to +somebody, apart from personal advantage or the desire to give pleasure, +do we speak of vanity. In this last case, a man wants to give himself +pleasure, but at the expense of his fellow creatures, inasmuch as he +inspires them with a false opinion of himself or else inspires "good +opinion" in such a way that it is a source of pain to others (by +arousing envy). The individual generally seeks, through the opinion of +others, to attest and fortify the opinion he has of himself; but the +potent influence of authority--an influence as old as man himself--leads +many, also, to strengthen their own opinion of themselves by means of +authority, that is, to borrow from others the expedient of relying more +upon the judgment of their fellow men than upon their own.--Interest in +oneself, the wish to please oneself attains, with the vain man, such +proportions that he first misleads others into a false, unduly exalted +estimate of himself and then relies upon the authority of others for his +self estimate; he thus creates the delusion that he pins his faith +to.--It must, however, be admitted that the vain man does not desire to +please others so much as himself and he will often go so far, on this +account, as to overlook his own interests: for he often inspires his +fellow creatures with malicious envy and renders them ill disposed in +order that he may thus increase his own delight in himself. + + +90 + +=Limits of the Love of Mankind.=--Every man who has declared that some +other man is an ass or a scoundrel, gets angry when the other man +conclusively shows that the assertion was erroneous. + + +91 + +=Weeping Morality.=--How much delight morality occasions! Think of the +ocean of pleasing tears that has flowed from the narration of noble, +great-hearted deeds!--This charm of life would disappear if the belief +in complete irresponsibility gained the upper hand. + + +92 + +=Origin of Justice.=--Justice (reasonableness) has its origin among +approximate equals in power, as Thucydides (in the dreadful conferences +of the Athenian and Melian envoys) has rightly conceived. Thus, where +there exists no demonstrable supremacy and a struggle leads but to +mutual, useless damage, the reflection arises that an understanding +would best be arrived at and some compromise entered into. The +reciprocal nature is hence the first nature of justice. Each party makes +the other content inasmuch as each receives what it prizes more highly +than the other. Each surrenders to the other what the other wants and +receives in return its own desire. Justice is therefore reprisal and +exchange upon the basis of an approximate equality of power. Thus +revenge pertains originally to the domain of justice as it is a sort of +reciprocity. Equally so, gratitude.--Justice reverts naturally to the +standpoint of self preservation, therefore to the egoism of this +consideration: "why should I injure myself to no purpose and perhaps +never attain my end?"--So much for the origin of justice. Only because +men, through mental habits, have forgotten the original motive of so +called just and rational acts, and also because for thousands of years +children have been brought to admire and imitate such acts, have they +gradually assumed the appearance of being unegotistical. Upon this +appearance is founded the high estimate of them, which, moreover, like +all estimates, is continually developing, for whatever is highly +esteemed is striven for, imitated, made the object of self sacrifice, +while the merit of the pain and emulation thus expended is, by each +individual, ascribed to the thing esteemed.--How slightly moral would +the world appear without forgetfulness! A poet could say that God had +posted forgetfulness as a sentinel at the portal of the temple of human +merit! + + +93 + +=Concerning the Law of the Weaker.=--Whenever any party, for instance, a +besieged city, yields to a stronger party, under stipulated conditions, +the counter stipulation is that there be a reduction to insignificance, +a burning and destruction of the city and thus a great damage inflicted +upon the stronger party. Thus arises a sort of equalization principle +upon the basis of which a law can be established. The enemy has an +advantage to gain by its maintenance.--To this extent there is also a +law between slaves and masters, limited only by the extent to which the +slave may be useful to his master. The law goes originally only so far +as the one party may appear to the other potent, invincible, stable, and +the like. To such an extent, then, the weaker has rights, but very +limited ones. Hence the famous dictum that each has as much law on his +side as his power extends (or more accurately, as his power is believed +to extend). + + +94 + +=The Three Phases of Morality Hitherto.=--It is the first evidence that +the animal has become human when his conduct ceases to be based upon the +immediately expedient, but upon the permanently useful; when he has, +therefore, grown utilitarian, capable of purpose. Thus is manifested the +first rule of reason. A still higher stage is attained when he regulates +his conduct upon the basis of honor, by means of which he gains mastery +of himself and surrenders his desires to principles; this lifts him far +above the phase in which he was actuated only by considerations of +personal advantage as he understood it. He respects and wishes to be +respected. This means that he comprehends utility as a thing dependent +upon what his opinion of others is and their opinion of him. Finally he +regulates his conduct (the highest phase of morality hitherto attained) +by his own standard of men and things. He himself decides, for himself +and for others, what is honorable and what is useful. He has become a +law giver to opinion, upon the basis of his ever higher developing +conception of the utilitarian and the honorable. Knowledge makes him +capable of placing the highest utility, (that is, the universal, +enduring utility) before merely personal utility,--of placing ennobling +recognition of the enduring and universal before the merely temporary: +he lives and acts as a collective individuality. + + +95 + +=Ethic of the Developed Individual.=--Hitherto the altruistic has been +looked upon as the distinctive characteristic of moral conduct, and it +is manifest that it was the consideration of universal utility that +prompted praise and recognition of altruistic conduct. Must not a +radical departure from this point of view be imminent, now that it is +being ever more clearly perceived that in the most personal +considerations the most general welfare is attained: so that conduct +inspired by the most personal considerations of advantage is just the +sort which has its origin in the present conception of morality (as a +universal utilitarianism)? To contemplate oneself as a complete +personality and bear the welfare of that personality in mind in all that +one does--this is productive of better results than any sympathetic +susceptibility and conduct in behalf of others. Indeed we all suffer +from such disparagement of our own personalities, which are at present +made to deteriorate from neglect. Capacity is, in fact, divorced from +our personality in most cases, and sacrificed to the state, to science, +to the needy, as if it were the bad which deserved to be made a +sacrifice. Now, we are willing to labor for our fellowmen but only to +the extent that we find our own highest advantage in so doing, no more, +no less. The whole matter depends upon what may be understood as one's +advantage: the crude, undeveloped, rough individualities will be the +very ones to estimate it most inadequately. + + +96 + +=Usage and Ethic.=--To be moral, virtuous, praiseworthy means to yield +obedience to ancient law and hereditary usage. Whether this obedience be +rendered readily or with difficulty is long immaterial. Enough that it +be rendered. "Good" finally comes to mean him who acts in the +traditional manner, as a result of heredity or natural disposition, that +is to say does what is customary with scarcely an effort, whatever that +may be (for example revenges injuries when revenge, as with the ancient +Greeks, was part of good morals). He is called good because he is good +"to some purpose," and as benevolence, sympathy, considerateness, +moderation and the like come, in the general course of conduct, to be +finally recognized as "good to some purpose" (as utilitarian) the +benevolent man, the helpful man, is duly styled "good". (At first other +and more important kinds of utilitarian qualities stand in the +foreground.) Bad is "not habitual" (unusual), to do things not in +accordance with usage, to oppose the traditional, however rational or +the reverse the traditional may be. To do injury to one's social group +or community (and to one's neighbor as thus understood) is looked upon, +through all the variations of moral laws, in different ages, as the +peculiarly "immoral" act, so that to-day we associate the word "bad" +with deliberate injury to one's neighbor or community. "Egoistic" and +"non-egoistic" do not constitute the fundamental opposites that have +brought mankind to make a distinction between moral and immoral, good +and bad; but adherence to traditional custom, and emancipation from it. +How the traditional had its origin is quite immaterial; in any event it +had no reference to good and bad or any categorical imperative but to +the all important end of maintaining and sustaining the community, the +race, the confederation, the nation. Every superstitious custom that +originated in a misinterpreted event or casualty entailed some +tradition, to adhere to which is moral. To break loose from it is +dangerous, more prejudicial to the community than to the individual +(because divinity visits the consequences of impiety and sacrilege upon +the community rather than upon the individual). Now every tradition +grows ever more venerable--the more remote is its origin, the more +confused that origin is. The reverence due to it increases from +generation to generation. The tradition finally becomes holy and +inspires awe. Thus it is that the precept of piety is a far loftier +morality than that inculcated by altruistic conduct. + + +97 + +=Delight in the Moral.=--A potent species of joy (and thereby the source +of morality) is custom. The customary is done more easily, better, +therefore preferably. A pleasure is felt in it and experience thus shows +that since this practice has held its own it must be good. A manner or +moral that lives and lets live is thus demonstrated advantageous, +necessary, in contradistinction to all new and not yet adopted +practices. The custom is therefore the blending of the agreeable and the +useful. Moreover it does not require deliberation. As soon as man can +exercise compulsion, he exercises it to enforce and establish his +customs, for they are to him attested lifewisdom. So, too, a community +of individuals constrains each one of their number to adopt the same +moral or custom. The error herein is this: Because a certain custom has +been agreeable to the feelings or at least because it proves a means of +maintenance, this custom must be imperative, for it is regarded as the +only thing that can possibly be consistent with well being. The well +being of life seems to spring from it alone. This conception of the +customary as a condition of existence is carried into the slightest +detail of morality. Inasmuch as insight into true causation is quite +restricted in all inferior peoples, a superstitious anxiety is felt that +everything be done in due routine. Even when a custom is exceedingly +burdensome it is preserved because of its supposed vital utility. It is +not known that the same degree of satisfaction can be experienced +through some other custom and even higher degrees of satisfaction, too. +But it is fully appreciated that all customs do become more agreeable +with the lapse of time, no matter how difficult they may have been found +in the beginning, and that even the severest way of life may be rendered +a matter of habit and therefore a pleasure. + + +98 + +=Pleasure and Social Instinct.=--Through his relations with other men, +man derives a new species of delight in those pleasurable emotions which +his own personality affords him; whereby the domain of pleasurable +emotions is made infinitely more comprehensive. No doubt he has +inherited many of these feelings from the brutes, which palpably feel +delight when they sport with one another, as mothers with their young. +So, too, the sexual relations must be taken into account: they make +every young woman interesting to every young man from the standpoint of +pleasure, and conversely. The feeling of pleasure originating in human +relationships makes men in general better. The delight in common, the +pleasures enjoyed together heighten one another. The individual feels a +sense of security. He becomes better natured. Distrust and malice +dissolve. For the man feels the sense of benefit and observes the same +feeling in others. Mutual manifestations of pleasure inspire mutual +sympathy, the sentiment of homogeneity. The same effect is felt also at +mutual sufferings, in a common danger, in stormy weather. Upon such a +foundation are built the earliest alliances: the object of which is the +mutual protection and safety from threatening misfortunes, and the +welfare of each individual. And thus the social instinct develops from +pleasure. + + +99 + +=The Guiltless Nature of So-Called Bad Acts.=--All "bad" acts are +inspired by the impulse to self preservation or, more accurately, by +the desire for pleasure and for the avoidance of pain in the individual. +Thus are they occasioned, but they are not, therefore, bad. "Pain self +prepared" does not exist, except in the brains of the philosophers, any +more than "pleasure self prepared" (sympathy in the Schopenhauer sense). +In the condition anterior to the state we kill the creature, be it man +or ape, that attempts to pluck the fruit of a tree before we pluck it +ourselves should we happen to be hungry at the time and making for that +tree: as we would do to-day, so far as the brute is concerned, if we +were wandering in savage regions.--The bad acts which most disturb us at +present do so because of the erroneous supposition that the one who is +guilty of them towards us has a free will in the matter and that it was +within his discretion not to have done these evil things. This belief in +discretionary power inspires hate, thirst for revenge, malice, the +entire perversion of the mental processes, whereas we would feel in no +way incensed against the brute, as we hold it irresponsible. To inflict +pain not from the instinct of self preservation but in requital--this is +the consequence of false judgment and is equally a guiltless course of +conduct. The individual can, in that condition which is anterior to the +state, act with fierceness and violence for the intimidation of another +creature, in order to render his own power more secure as a result of +such acts of intimidation. Thus acts the powerful, the superior, the +original state founder, who subjugates the weaker. He has the right to +do so, as the state nowadays assumes the same right, or, to be more +accurate, there is no right that can conflict with this. A foundation +for all morality can first be laid only when a stronger individuality or +a collective individuality, for example society, the state, subjects the +single personalities, hence builds upon their unification and +establishes a bond of union. Morality results from compulsion, it is +indeed itself one long compulsion to which obedience is rendered in +order that pain may be avoided. At first it is but custom, later free +obedience and finally almost instinct. At last it is (like everything +habitual and natural) associated with pleasure--and is then called +virtue. + + +100 + +=Shame.=--Shame exists wherever a "mystery" exists: but this is a +religious notion which in the earlier period of human civilization had +great vogue. Everywhere there were circumscribed spots to which access +was denied on account of some divine law, except in special +circumstances. At first these spots were quite extensive, inasmuch as +stipulated areas could not be trod by the uninitiated, who, when near +them, felt tremors and anxieties. This sentiment was frequently +transferred to other relationships, for example to sexual relations, +which, as the privilege and gateway of mature age, must be withdrawn +from the contemplation of youth for its own advantage: relations which +many divinities were busy in preserving and sanctifying, images of which +divinities were duly placed in marital chambers as guardians. (In +Turkish such an apartment is termed a harem or holy thing, the same word +also designating the vestibule of a mosque). So, too, Kingship is +regarded as a centre from which power and brilliance stream forth, as a +mystery to the subjects, impregnated with secrecy and shame, sentiments +still quite operative among peoples who in other respects are without +any shame at all. So, too, is the whole world of inward states, the +so-called "soul," even now, for all non-philosophical persons, a +"mystery," and during countless ages it was looked upon as a something +of divine origin, in direct communion with deity. It is, therefore, an +adytum and occasions shame. + + +101 + +=Judge Not.=--Care must be taken, in the contemplation of earlier ages, +that there be no falling into unjust scornfulness. The injustice in +slavery, the cruelty in the subjugation of persons and peoples must not +be estimated by our standard. For in that period the instinct of justice +was not so highly developed. Who dare reproach the Genoese Calvin for +burning the physician Servetus at the stake? It was a proceeding growing +out of his convictions. And the Inquisition, too, had its justification. +The only thing is that the prevailing views were false and led to those +proceedings which seem so cruel to us, simply because such views have +become foreign to us. Besides, what is the burning alive of one +individual compared with eternal hell pains for everybody else? And yet +this idea then had hold of all the world without in the least vitiating, +with its frightfulness, the other idea of a god. Even we nowadays are +hard and merciless to political revolutionists, but that is because we +are in the habit of believing the state a necessity, and hence the +cruelty of the proceeding is not so much understood as in the other +cases where the points of view are repudiated. The cruelty to animals +shown by children and Italians is due to the same misunderstanding. The +animal, owing to the exigencies of the church catechism, is placed too +far below the level of mankind.--Much, too, that is frightful and +inhuman in history, and which is almost incredible, is rendered less +atrocious by the reflection that the one who commands and the one who +executes are different persons. The former does not witness the +performance and hence it makes no strong impression on him. The latter +obeys a superior and hence feels no responsibility. Most princes and +military chieftains appear, through lack of true perception, cruel and +hard without really being so.--Egoism is not bad because the idea of the +"neighbor"--the word is of Christian origin and does not correspond to +truth--is very weak in us, and we feel ourselves, in regard to him, as +free from responsibility as if plants and stones were involved. That +another is in suffering must be learned and it can never be wholly +learned. + + +102 + +"=Man Always Does Right.="--We do not blame nature when she sends a +thunder storm and makes us wet: why then do we term the man who inflicts +injury immoral? Because in the latter case we assume a voluntary, +ruling, free will, and in the former necessity. But this distinction is +a delusion. Moreover, even the intentional infliction of injury is not, +in all circumstances termed immoral. Thus, we kill a fly intentionally +without thinking very much about it, simply because its buzzing about is +disagreeable; and we punish a criminal and inflict pain upon him in +order to protect ourselves and society. In the first case it is the +individual who, for the sake of preserving himself or in order to spare +himself pain, does injury with design: in the second case, it is the +state. All ethic deems intentional infliction of injury justified by +necessity; that is when it is a matter of self preservation. But these +two points of view are sufficient to explain all bad acts done by man to +men. It is desired to obtain pleasure or avoid pain. In any sense, it is +a question, always, of self preservation. Socrates and Plato are right: +whatever man does he always does right: that is, does what seems to him +good (advantageous) according to the degree of advancement his intellect +has attained, which is always the measure of his rational capacity. + + +103 + +=The Inoffensive in Badness.=--Badness has not for its object the +infliction of pain upon others but simply our own satisfaction as, for +instance, in the case of thirst for vengeance or of nerve excitation. +Every act of teasing shows what pleasure is caused by the display of +our power over others and what feelings of delight are experienced in +the sense of domination. Is there, then, anything immoral in feeling +pleasure in the pain of others? Is malicious joy devilish, as +Schopenhauer says? In the realm of nature we feel joy in breaking +boughs, shattering rocks, fighting with wild beasts, simply to attest +our strength thereby. Should not the knowledge that another suffers on +our account here, in this case, make the same kind of act, (which, by +the way, arouses no qualms of conscience in us) immoral also? But if we +had not this knowledge there would be no pleasure in one's own +superiority or power, for this pleasure is experienced only in the +suffering of another, as in the case of teasing. All pleasure is, in +itself, neither good nor bad. Whence comes the conviction that one +should not cause pain in others in order to feel pleasure oneself? +Simply from the standpoint of utility, that is, in consideration of the +consequences, of ultimate pain, since the injured party or state will +demand satisfaction and revenge. This consideration alone can have led +to the determination to renounce such pleasure.--Sympathy has the +satisfaction of others in view no more than, as already stated, badness +has the pain of others in view. For there are at least two (perhaps many +more) elementary ingredients in personal gratification which enter +largely into our self satisfaction: one of them being the pleasure of +the emotion, of which species is sympathy with tragedy, and another, +when the impulse is to action, being the pleasure of exercising one's +power. Should a sufferer be very dear to us, we divest ourselves of pain +by the performance of acts of sympathy.--With the exception of some few +philosophers, men have placed sympathy very low in the rank of moral +feelings: and rightly. + + +104 + +=Self Defence.=--If self defence is in general held a valid +justification, then nearly every manifestation of so called immoral +egoism must be justified, too. Pain is inflicted, robbery or killing +done in order to maintain life or to protect oneself and ward off harm. +A man lies when cunning and delusion are valid means of self +preservation. To injure intentionally when our safety and our existence +are involved, or the continuance of our well being, is conceded to be +moral. The state itself injures from this motive when it hangs +criminals. In unintentional injury the immoral, of course, can not be +present, as accident alone is involved. But is there any sort of +intentional injury in which our existence and the maintenance of our +well being be not involved? Is there such a thing as injuring from +absolute badness, for example, in the case of cruelty? If a man does not +know what pain an act occasions, that act is not one of wickedness. Thus +the child is not bad to the animal, not evil. It disturbs and rends it +as if it were one of its playthings. Does a man ever fully know how much +pain an act may cause another? As far as our nervous system extends, we +shield ourselves from pain. If it extended further, that is, to our +fellow men, we would never cause anyone else any pain (except in such +cases as we cause it to ourselves, when we cut ourselves, surgically, to +heal our ills, or strive and trouble ourselves to gain health). We +conclude from analogy that something pains somebody and can in +consequence, through recollection and the power of imagination, feel +pain also. But what a difference there always is between the tooth ache +and the pain (sympathy) that the spectacle of tooth ache occasions! +Therefore when injury is inflicted from so called badness the degree of +pain thereby experienced is always unknown to us: in so far, however, as +pleasure is felt in the act (a sense of one's own power, of one's own +excitation) the act is committed to maintain the well being of the +individual and hence comes under the purview of self defence and lying +for self preservation. Without pleasure, there is no life; the struggle +for pleasure is the struggle for life. Whether the individual shall +carry on this struggle in such a way that he be called good or in such a +way that he be called bad is something that the standard and the +capacity of his own intellect must determine for him. + + +105 + +=Justice that Rewards.=--Whoever has fully understood the doctrine of +absolute irresponsibility can no longer include the so called rewarding +and punishing justice in the idea of justice, if the latter be taken to +mean that to each be given his due. For he who is punished does not +deserve the punishment. He is used simply as a means to intimidate +others from certain acts. Equally, he who is rewarded does not merit the +reward. He could not act any differently than he did act. Hence the +reward has only the significance of an encouragement to him and others +as a motive for subsequent acts. The praise is called out only to him +who is running in the race and not to him who has arrived at the goal. +Something that comes to someone as his own is neither a punishment nor a +reward. It is given to him from utiliarian considerations, without his +having any claim to it in justice. Hence one must say "the wise man +praises not because a good act has been done" precisely as was once +said: "the wise man punishes not because a bad act has been done but in +order that a bad act may not be done." If punishment and reward ceased, +there would cease with them the most powerful incentives to certain acts +and away from other acts. The purposes of men demand their continuance +[of punishment and reward] and inasmuch as punishment and reward, blame +and praise operate most potently upon vanity, these same purposes of men +imperatively require the continuance of vanity. + + +106 + +=The Water Fall.=--At the sight of a water fall we may opine that in the +countless curves, spirations and dashes of the waves we behold freedom +of the will and of the impulses. But everything is compulsory, +everything can be mathematically calculated. Thus it is, too, with human +acts. We would be able to calculate in advance every single action if we +were all knowing, as well as every advance in knowledge, every delusion, +every bad deed. The acting individual himself is held fast in the +illusion of volition. If, on a sudden, the entire movement of the world +stopped short, and an all knowing and reasoning intelligence were there +to take advantage of this pause, he could foretell the future of every +being to the remotest ages and indicate the path that would be taken in +the world's further course. The deception of the acting individual as +regards himself, the assumption of the freedom of the will, is a part of +this computable mechanism. + + +107 + +=Non-Responsibility and Non-Guilt.=--The absolute irresponsibility of +man for his acts and his nature is the bitterest drop in the cup of him +who has knowledge, if he be accustomed to behold in responsibility and +duty the patent of nobility of his human nature. All his estimates, +preferences, dislikes are thus made worthless and false. His deepest +sentiment, with which he honored the sufferer, the hero, sprang from an +error. He may no longer praise, no longer blame, for it is irrational to +blame and praise nature and necessity. Just as he cherishes the +beautiful work of art, but does not praise it (as it is incapable of +doing anything for itself), just as he stands in the presence of plants, +he must stand in the presence of human conduct, his own included. He may +admire strength, beauty, capacity, therein, but he can discern no merit. +The chemical process and the conflict of the elements, the ordeal of +the invalid who strives for convalescence, are no more merits than the +soul-struggles and extremities in which one is torn this way and that by +contending motives until one finally decides in favor of the +strongest--as the phrase has it, although, in fact, it is the strongest +motive that decides for us. All these motives, however, whatever fine +names we may give them, have grown from the same roots in which we +believe the baneful poisons lurk. Between good and bad actions there is +no difference in kind but, at most, in degree. Good acts are sublimated +evil. Bad acts are degraded, imbruted good. The very longing of the +individual for self gratification (together with the fear of being +deprived of it) obtains satisfaction in all circumstances, let the +individual act as he may, that is, as he must: be it in deeds of vanity, +revenge, pleasure, utility, badness, cunning, be it in deeds of self +sacrifice, sympathy or knowledge. The degrees of rational capacity +determine the direction in which this longing impels: every society, +every individual has constantly present a comparative classification of +benefits in accordance with which conduct is determined and others are +judged. But this standard perpetually changes. Many acts are called bad +that are only stupid, because the degree of intelligence that decided +for them was low. Indeed, in a certain sense, all acts now are stupid, +for the highest degree of human intelligence that has yet been attained +will in time most certainly be surpassed and then, in retrospection, all +our present conduct and opinion will appear as narrow and petty as we +now deem the conduct and opinion of savage peoples and ages.--To +perceive all these things may occasion profound pain but there is, +nevertheless, a consolation. Such pains are birth pains. The butterfly +insists upon breaking through the cocoon, he presses through it, tears +it to pieces, only to be blinded and confused by the strange light, by +the realm of liberty. By such men as are capable of this sadness--how +few there are!--will the first attempt be made to see if humanity may +convert itself from a thing of morality to a thing of wisdom. The sun of +a new gospel sheds its first ray upon the loftiest height in the souls +of those few: but the clouds are massed there, too, thicker than ever, +and not far apart are the brightest sunlight and the deepest gloom. +Everything is necessity--so says the new knowledge: and this knowledge +is itself necessity. All is guiltlessness, and knowledge is the way to +insight into this guiltlessness. If pleasure, egoism, vanity be +necessary to attest the moral phenomena and their richest blooms, the +instinct for truth and accuracy of knowledge; if delusion and confusion +of the imagination were the only means whereby mankind could gradually +lift itself up to this degree of self enlightenment and self +emancipation--who would venture to disparage the means? Who would have +the right to feel sad if made aware of the goal to which those paths +lead? Everything in the domain of ethic is evolved, changeable, +tottering; all things flow, it is true--but all things are also in the +stream: to their goal. Though within us the hereditary habit of +erroneous judgment, love, hate, may be ever dominant, yet under the +influence of awaking knowledge it will ever become weaker: a new habit, +that of understanding, not-loving, not-hating, looking from above, grows +up within us gradually and in the same soil, and may, perhaps, in +thousands of years be powerful enough to endow mankind with capacity to +develop the wise, guiltless man (conscious of guiltlessness) as +unfailingly as it now developes the unwise, irrational, guilt-conscious +man--that is to say, the necessary higher step, not the opposite of it. + + + + +THE RELIGIOUS LIFE. + + +108 + +=The Double Contest Against Evil.=--If an evil afflicts us we can either +so deal with it as to remove its cause or else so deal with it that its +effect upon our feeling is changed: hence look upon the evil as a +benefit of which the uses will perhaps first become evident in some +subsequent period. Religion and art (and also the metaphysical +philosophy) strive to effect an alteration of the feeling, partly by an +alteration of our judgment respecting the experience (for example, with +the aid of the dictum "whom God loves, he chastizes") partly by the +awakening of a joy in pain, in emotion especially (whence the art of +tragedy had its origin). The more one is disposed to interpret away and +justify, the less likely he is to look directly at the causes of evil +and eliminate them. An instant alleviation and narcotizing of pain, as +is usual in the case of tooth ache, is sufficient for him even in the +severest suffering. The more the domination of religions and of all +narcotic arts declines, the more searchingly do men look to the +elimination of evil itself, which is a rather bad thing for the tragic +poets--for there is ever less and less material for tragedy, since the +domain of unsparing, immutable destiny grows constantly more +circumscribed--and a still worse thing for the priests, for these last +have lived heretofore upon the narcoticizing of human ill. + + +109 + +=Sorrow is Knowledge.=--How willingly would not one exchange the false +assertions of the homines religiosi that there is a god who commands us +to be good, who is the sentinel and witness of every act, every moment, +every thought, who loves us, who plans our welfare in every +misfortune--how willingly would not one exchange these for truths as +healing, beneficial and grateful as those delusions! But there are no +such truths. Philosophy can at most set up in opposition to them other +metaphysical plausibilities (fundamental untruths as well). The tragedy +of it all is that, although one cannot believe these dogmas of religion +and metaphysics if one adopts in heart and head the potent methods of +truth, one has yet become, through human evolution, so tender, +susceptible, sensitive, as to stand in need of the most effective means +of rest and consolation. From this state of things arises the danger +that, through the perception of truth or, more accurately, seeing +through delusion, one may bleed to death. Byron has put this into +deathless verse: + + "Sorrow is knowledge: they who know the most + Must mourn the deepest o'er the fatal truth, + The tree of knowledge is not that of life." + +Against such cares there is no better protective than the light fancy of +Horace, (at any rate during the darkest hours and sun eclipses of the +soul) expressed in the words + + "quid aeternis minorem + consiliis animum fatigas? + cur non sub alta vel platano vel hac + pinu jacentes."[22] + +[22] Then wherefore should you, who are mortal, outwear + Your soul with a profitless burden of care + Say, why should we not, flung at ease neath this pine, + Or a plane-tree's broad umbrage, quaff gaily our wine? + (Translation of Sir Theodore Martin.) + +At any rate, light fancy or heavy heartedness of any degree must be +better than a romantic retrogression and desertion of one's flag, an +approach to Christianity in any form: for with it, in the present state +of knowledge, one can have nothing to do without hopelessly defiling +one's intellectual integrity and surrendering it unconditionally. These +woes may be painful enough, but without pain one cannot become a leader +and guide of humanity: and woe to him who would be such and lacks this +pure integrity of the intellect! + + +110 + +=The Truth in Religion.=--In the ages of enlightenment justice was not +done to the importance of religion, of this there can be no doubt. It is +also equally certain that in the ensuing reaction of enlightenment, the +demands of justice were far exceeded inasmuch as religion was treated +with love, even with infatuation and proclaimed as a profound, indeed +the most profound knowledge of the world, which science had but to +divest of its dogmatic garb in order to possess "truth" in its +unmythical form. Religions must therefore--this was the contention of +all foes of enlightenment--sensu allegorico, with regard for the +comprehension of the masses, give expression to that ancient truth which +is wisdom in itself, inasmuch as all science of modern times has led up +to it instead of away from it. So that between the most ancient wisdom +of man and all later wisdom there prevails harmony, even similarity of +viewpoint; and the advancement of knowledge--if one be disposed to +concede such a thing--has to do not with its nature but with its +propagation. This whole conception of religion and science is through +and through erroneous, and none would to-day be hardy enough to +countenance it had not Schopenhauer's rhetoric taken it under +protection, this high sounding rhetoric which now gains auditors after +the lapse of a generation. Much as may be gained from Schopenhauer's +religio-ethical human and cosmical oracle as regards the comprehension +of Christianity and other religions, it is nevertheless certain that he +erred regarding the value of religion to knowledge. He himself was in +this but a servile pupil of the scientific teachers of his time who had +all taken romanticism under their protection and renounced the spirit of +enlightenment. Had he been born in our own time it would have been +impossible for him to have spoken of the sensus allegoricus of religion. +He would instead have done truth the justice to say: never has a +religion, directly or indirectly, either as dogma or as allegory, +contained a truth. For all religions grew out of dread or necessity, and +came into existence through an error of the reason. They have, perhaps, +in times of danger from science, incorporated some philosophical +doctrine or other into their systems in order to make it possible to +continue one's existence within them. But this is but a theological work +of art dating from the time in which a religion began to doubt of +itself. These theological feats of art, which are most common in +Christianity as the religion of a learned age, impregnated with +philosophy, have led to this superstition of the sensus allegoricus, as +has, even more, the habit of the philosophers (namely those +half-natures, the poetical philosophers and the philosophising artists) +of dealing with their own feelings as if they constituted the +fundamental nature of humanity and hence of giving their own religious +feelings a predominant influence over the structure of their systems. As +the philosophers mostly philosophised under the influence of hereditary +religious habits, or at least under the traditional influence of this +"metaphysical necessity," they naturally arrived at conclusions +closely resembling the Judaic or Christian or Indian religious +tenets--resembling, in the way that children are apt to look like their +mothers: only in this case the fathers were not certain as to the +maternity, as easily happens--but in the innocence of their admiration, +they fabled regarding the family likeness of all religion and science. +In reality, there exists between religion and true science neither +relationship nor friendship, not even enmity: they dwell in different +spheres. Every philosophy that lets the religious comet gleam through +the darkness of its last outposts renders everything within it that +purports to be science, suspicious. It is all probably religion, +although it may assume the guise of science.--Moreover, though all the +peoples agree concerning certain religious things, for example, the +existence of a god (which, by the way, as regards this point, is not +the case) this fact would constitute an argument against the thing +agreed upon, for example the very existence of a god. The consensus +gentium and especially hominum can probably amount only to an absurdity. +Against it there is no consensus omnium sapientium whatever, on any +point, with the exception of which Goethe's verse speaks: + + "All greatest sages to all latest ages + Will smile, wink and slily agree + 'Tis folly to wait till a fool's empty pate + Has learned to be knowing and free. + So children of wisdom must look upon fools + As creatures who're never the better for schools." + +Stated without rhyme or metre and adapted to our case: the consensus +sapientium is to the effect that the consensus gentium amounts to an +absurdity. + + +111 + +=Origin of Religious Worship.=--Let us transport ourselves back to the +times in which religious life flourished most vigorously and we will +find a fundamental conviction prevalent which we no longer share and +which has resulted in the closing of the door to religious life once for +all so far as we are concerned: this conviction has to do with nature +and intercourse with her. In those times nothing is yet known of +nature's laws. Neither for earth nor for heaven is there a must. A +season, sunshine, rain can come or stay away as it pleases. There is +wanting, in particular, all idea of natural causation. If a man rows, it +is not the oar that moves the boat, but rowing is a magical ceremony +whereby a demon is constrained to move the boat. All illness, death +itself, is a consequence of magical influences. In sickness and death +nothing natural is conceived. The whole idea of "natural course" is +wanting. The idea dawns first upon the ancient Greeks, that is to say in +a very late period of humanity, in the conception of a Moira [fate] +ruling over the gods. If any person shoots off a bow, there is always an +irrational strength and agency in the act. If the wells suddenly run +dry, the first thought is of subterranean demons and their pranks. It +must have been the dart of a god beneath whose invisible influence a +human being suddenly collapses. In India, the carpenter (according to +Lubbock) is in the habit of making devout offerings to his hammer and +hatchet. A Brahmin treats the plume with which he writes, a soldier the +weapon that he takes into the field, a mason his trowel, a laborer his +plow, in the same way. All nature is, in the opinion of religious +people, a sum total of the doings of conscious and willing beings, an +immense mass of complex volitions. In regard to all that takes place +outside of us no conclusion is permissible that anything will result +thus and so, must result thus and so, that we are comparatively +calculable and certain in our experiences, that man is the rule, nature +the ruleless. This view forms the fundamental conviction that dominates +crude, religion-producing, early civilizations. We contemporary men feel +exactly the opposite: the richer man now feels himself inwardly, the +more polyphone the music and the sounding of his soul, the more +powerfully does the uniformity of nature impress him. We all, with +Goethe, recognize in nature the great means of repose for the soul. We +listen to the pendulum stroke of this great clock with longing for rest, +for absolute calm and quiescence, as if we could drink in the uniformity +of nature and thereby arrive first at an enjoyment of oneself. Formerly +it was the reverse: if we carry ourselves back to the periods of crude +civilization, or if we contemplate contemporary savages, we will find +them most strongly influenced by rule, by tradition. The individual is +almost automatically bound to rule and tradition and moves with the +uniformity of a pendulum. To him nature--the uncomprehended, fearful, +mysterious nature--must seem the domain of freedom, of volition, of +higher power, indeed as an ultra-human degree of destiny, as god. Every +individual in such periods and circumstances feels that his existence, +his happiness, the existence and happiness of the family, the state, +the success or failure of every undertaking, must depend upon these +dispositions of nature. Certain natural events must occur at the proper +time and certain others must not occur. How can influence be exercised +over this fearful unknown, how can this domain of freedom be brought +under subjection? thus he asks himself, thus he worries: Is there no +means to render these powers of nature as subject to rule and tradition +as you are yourself?--The cogitation of the superstitious and +magic-deluded man is upon the theme of imposing a law upon nature: and +to put it briefly, religious worship is the result of such cogitation. +The problem which is present to every man is closely connected with this +one: how can the weaker party dictate laws to the stronger, control its +acts in reference to the weaker? At first the most harmless form of +influence is recollected, that influence which is acquired when the +partiality of anyone has been won. Through beseeching and prayer, +through abject humiliation, through obligations to regular gifts and +propitiations, through flattering homages, it is possible, therefore, to +impose some guidance upon the forces of nature, to the extent that their +partiality be won: love binds and is bound. Then agreements can be +entered into by means of which certain courses of conduct are mutually +concluded, vows are made and authorities prescribed. But far more potent +is that species of power exercised by means of magic and incantation. As +a man is able to injure a powerful enemy by means of the magician and +render him helpless with fear, as the love potion operates at a +distance, so can the mighty forces of nature, in the opinion of weaker +mankind, be controlled by similar means. The principal means of +effecting incantations is to acquire control of something belonging to +the party to be influenced, hair, finger nails, food from his table, +even his picture or his name. With such apparatus it is possible to act +by means of magic, for the basic principle is that to everything +spiritual corresponds something corporeal. With the aid of this +corporeal element the spirit may be bound, injured or destroyed. The +corporeal affords the handle by which the spiritual can be laid hold of. +In the same way that man influences mankind does he influences some +spirit of nature, for this latter has also its corporeal element that +can be grasped. The tree, and on the same basis, the seed from which it +grew: this puzzling sequence seems to demonstrate that in both forms the +same spirit is embodied, now large, now small. A stone that suddenly +rolls, is the body in which the spirit works. Does a huge boulder lie in +a lonely moor? It is impossible to think of mortal power having placed +it there. The stone must have moved itself there. That is to say some +spirit must dominate it. Everything that has a body is subject to magic, +including, therefore, the spirits of nature. If a god is directly +connected with his portrait, a direct influence (by refraining from +devout offerings, by whippings, chainings and the like) can be brought +to bear upon him. The lower classes in China tie cords around the +picture of their god in order to defy his departing favor, when he has +left them in the lurch, and tear the picture to pieces, drag it through +the streets into dung heaps and gutters, crying: "You dog of a spirit, +we housed you in a beautiful temple, we gilded you prettily, we fed you +well, we brought you offerings, and yet how ungrateful you are!" Similar +displays of resentment have been made against pictures of the mother of +god and pictures of saints in Catholic countries during the present +century when such pictures would not do their duty during times of +pestilence and drought. + +Through all these magical relationships to nature countless ceremonies +are occasioned, and finally, when their complexity and confusion grow +too great, pains are taken to systematize them, to arrange them so that +the favorable course of nature's progress, namely the great yearly +circle of the seasons, may be brought about by a corresponding course of +the ceremonial progress. The aim of religious worship is to influence +nature to human advantage, and hence to instil a subjection to law into +her that originally she has not, whereas at present man desires to find +out the subjection to law of nature in order to guide himself thereby. +In brief, the system of religious worship rests upon the idea of magic +between man and man, and the magician is older than the priest. But it +rests equally upon other and higher ideas. It brings into prominence the +sympathetic relation of man to man, the existence of benevolence, +gratitude, prayer, of truces between enemies, of loans upon security, of +arrangements for the protection of property. Man, even in very inferior +degrees of civilization, does not stand in the presence of nature as a +helpless slave, he is not willy-nilly the absolute servant of nature. In +the Greek development of religion, especially in the relationship to the +Olympian gods, it becomes possible to entertain the idea of an existence +side by side of two castes, a higher, more powerful, and a lower, less +powerful: but both are bound together in some way, on account of their +origin and are one species. They need not be ashamed of one another. +This is the element of distinction in Greek religion. + + +112 + +=At the Contemplation of Certain Ancient Sacrificial Proceedings.=--How +many sentiments are lost to us is manifest in the union of the farcical, +even of the obscene, with the religious feeling. The feeling that this +mixture is possible is becoming extinct. We realize the mixture only +historically, in the mysteries of Demeter and Dionysos and in the +Christian Easter festivals and religious mysteries. But we still +perceive the sublime in connection with the ridiculous, and the like, +the emotional with the absurd. Perhaps a later age will be unable to +understand even these combinations. + + +113 + +=Christianity as Antiquity.=--When on a Sunday morning we hear the old +bells ringing, we ask ourselves: Is it possible? All this for a Jew +crucified two thousand years ago who said he was God's son? The proof of +such an assertion is lacking.--Certainly, the Christian religion +constitutes in our time a protruding bit of antiquity from very remote +ages and that its assertions are still generally believed--although men +have become so keen in the scrutiny of claims--constitutes the oldest +relic of this inheritance. A god who begets children by a mortal woman; +a sage who demands that no more work be done, that no more justice be +administered but that the signs of the approaching end of the world be +heeded; a system of justice that accepts an innocent as a vicarious +sacrifice in the place of the guilty; a person who bids his disciples +drink his blood; prayers for miracles; sins against a god expiated upon +a god; fear of a hereafter to which death is the portal; the figure of +the cross as a symbol in an age that no longer knows the purpose and the +ignominy of the cross--how ghostly all these things flit before us out +of the grave of their primitive antiquity! Is one to believe that such +things can still be believed? + + +114 + +=The Un-Greek in Christianity.=--The Greeks did not look upon the +Homeric gods above them as lords nor upon themselves beneath as +servants, after the fashion of the Jews. They saw but the counterpart as +in a mirror of the most perfect specimens of their own caste, hence an +ideal, but no contradiction of their own nature. There was a feeling of +mutual relationship, resulting in a mutual interest, a sort of alliance. +Man thinks well of himself when he gives himself such gods and places +himself in a relationship akin to that of the lower nobility with the +higher; whereas the Italian races have a decidedly vulgar religion, +involving perpetual anxiety because of bad and mischievous powers and +soul disturbers. Wherever the Olympian gods receded into the background, +there even Greek life became gloomier and more perturbed.--Christianity, +on the other hand, oppressed and degraded humanity completely and sank +it into deepest mire: into the feeling of utter abasement it suddenly +flashed the gleam of divine compassion, so that the amazed and +grace-dazzled stupefied one gave a cry of delight and for a moment +believed that the whole of heaven was within him. Upon this unhealthy +excess of feeling, upon the accompanying corruption of heart and head, +Christianity attains all its psychological effects. It wants to +annihilate, debase, stupefy, amaze, bedazzle. There is but one thing +that it does not want: measure, standard (das Maas) and therefore is it +in the worst sense barbarous, asiatic, vulgar, un-Greek. + + +115 + +=Being Religious to Some Purpose.=--There are certain insipid, +traffic-virtuous people to whom religion is pinned like the hem of some +garb of a higher humanity. These people do well to remain religious: it +adorns them. All who are not versed in some professional +weapon--including tongue and pen as weapons--are servile: to all such +the Christian religion is very useful, for then their servility assumes +the aspect of Christian virtue and is amazingly adorned.--People whose +daily lives are empty and colorless are readily religious. This is +comprehensible and pardonable, but they have no right to demand that +others, whose daily lives are not empty and colorless, should be +religious also. + + +116 + +=The Everyday Christian.=--If Christianity, with its allegations of an +avenging God, universal sinfulness, choice of grace, and the danger of +eternal damnation, were true, it would be an indication of weakness of +mind and character not to be a priest or an apostle or a hermit, and +toil for one's own salvation. It would be irrational to lose sight of +one's eternal well being in comparison with temporary advantage: +Assuming these dogmas to be generally believed, the every day Christian +is a pitiable figure, a man who really cannot count as far as three, and +who, for the rest, just because of his intellectual incapacity, does not +deserve to be as hard punished as Christianity promises he shall be. + + +117 + +=Concerning the Cleverness of Christianity.=--It is a master stroke of +Christianity to so emphasize the unworthiness, sinfulness and +degradation of men in general that contempt of one's fellow creatures +becomes impossible. "He may sin as much as he pleases, he is not by +nature different from me. It is I who in every way am unworthy and +contemptible." So says the Christian to himself. But even this feeling +has lost its keenest sting for the Christian does not believe in his +individual degradation. He is bad in his general human capacity and he +soothes himself a little with the assertion that we are all alike. + + +118 + +=Personal Change.=--As soon as a religion rules, it has for its +opponents those who were its first disciples. + + +119 + +=Fate of Christianity.=--Christianity arose to lighten the heart, but +now it must first make the heart heavy in order to be able to lighten it +afterwards. Christianity will consequently go down. + + +120 + +=The Testimony of Pleasure.=--The agreeable opinion is accepted as true. +This is the testimony of pleasure (or as the church says, the evidence +of strength) of which all religions are so proud, although they should +all be ashamed of it. If a belief did not make blessed it would not be +believed. How little it would be worth, then! + + +121 + +=Dangerous Play.=--Whoever gives religious feeling room, must then also +let it grow. He can do nothing else. Then his being gradually changes. +The religious element brings with it affinities and kinships. The whole +circle of his judgment and feeling is clouded and draped in religious +shadows. Feeling cannot stand still. One should be on one's guard. + + +122 + +=The Blind Pupil.=--As long as one knows very well the strength and the +weakness of one's dogma, one's art, one's religion, its strength is +still low. The pupil and apostle who has no eye for the weaknesses of a +dogma, a religion and so on, dazzled by the aspect of the master and by +his own reverence for him, has, on that very account, generally more +power than the master. Without blind pupils the influence of a man and +his work has never become great. To give victory to knowledge, often +amounts to no more than so allying it with stupidity that the brute +force of the latter forces triumph for the former. + + +123 + +=The Breaking off of Churches.=--There is not sufficient religion in the +world merely to put an end to the number of religions. + + +124 + +=Sinlessness of Men.=--If one have understood how "Sin came into the +world," namely through errors of the reason, through which men in their +intercourse with one another and even individual men looked upon +themselves as much blacker and wickeder than was really the case, one's +whole feeling is much lightened and man and the world appear together in +such a halo of harmlessness that a sentiment of well being is instilled +into one's whole nature. Man in the midst of nature is as a child left +to its own devices. This child indeed dreams a heavy, anxious dream. But +when it opens its eyes it finds itself always in paradise. + + +125 + +=Irreligiousness of Artists.=--Homer is so much at home among his gods +and is as a poet so good natured to them that he must have been +profoundly irreligious. That which was brought to him by the popular +faith--a mean, crude and partially repulsive superstition--he dealt with +as freely as the Sculptor with his clay, therefore with the same freedom +that Æschylus and Aristophanes evinced and with which in later times the +great artists of the renaissance, and also Shakespeare and Goethe, drew +their pictures. + + +126 + +=Art and Strength of False Interpretation.=--All the visions, fears, +exhaustions and delights of the saint are well known symptoms of +sickness, which in him, owing to deep rooted religious and psychological +delusions, are explained quite differently, that is not as symptoms of +sickness.--So, too, perhaps, the demon of Socrates was nothing but a +malady of the ear that he explained, in view of his predominant moral +theory, in a manner different from what would be thought rational +to-day. Nor is the case different with the frenzy and the frenzied +speeches of the prophets and of the priests of the oracles. It is always +the degree of wisdom, imagination, capacity and morality in the heart +and mind of the interpreters that got so much out of them. It is among +the greatest feats of the men who are called geniuses and saints that +they made interpreters for themselves who, fortunately for mankind, did +not understand them. + + +127 + +=Reverence for Madness.=--Because it was perceived that an excitement of +some kind often made the head clearer and occasioned fortunate +inspirations, it was concluded that the utmost excitement would occasion +the most fortunate inspirations. Hence the frenzied being was revered as +a sage and an oracle giver. A false conclusion lies at the bottom of all +this. + + +128 + +=Promises of Wisdom.=--Modern science has as its object as little pain +as possible, as long a life as possible--hence a sort of eternal +blessedness, but of a very limited kind in comparison with the promises +of religion. + + +129 + +=Forbidden Generosity.=--There is not enough of love and goodness in the +world to throw any of it away on conceited people. + + +130 + +=Survival of Religious Training in the Disposition.=--The Catholic +Church, and before it all ancient education, controlled the whole domain +of means through which man was put into certain unordinary moods and +withdrawn from the cold calculation of personal advantage and from calm, +rational reflection. A church vibrating with deep tones; gloomy, +regular, restraining exhortations from a priestly band, who +involuntarily communicate their own tension to their congregation and +lead them to listen almost with anxiety as if some miracle were in +course of preparation; the awesome pile of architecture which, as the +house of a god, rears itself vastly into the vague and in all its +shadowy nooks inspires fear of its nerve-exciting power--who would care +to reduce men to the level of these things if the ideas upon which they +rest became extinct? But the results of all these things are +nevertheless not thrown away: the inner world of exalted, emotional, +prophetic, profoundly repentant, hope-blessed moods has become inborn in +man largely through cultivation. What still exists in his soul was +formerly, as he germinated, grew and bloomed, thoroughly disciplined. + + +131 + +=Religious After-Pains.=--Though one believe oneself absolutely weaned +away from religion, the process has yet not been so thorough as to make +impossible a feeling of joy at the presence of religious feelings and +dispositions without intelligible content, as, for example, in music; +and if a philosophy alleges to us the validity of metaphysical hopes, +through the peace of soul therein attainable, and also speaks of "the +whole true gospel in the look of Raphael's Madonna," we greet such +declarations and innuendoes with a welcome smile. The philosopher has +here a matter easy of demonstration. He responds with that which he is +glad to give, namely a heart that is glad to accept. Hence it is +observable how the less reflective free spirits collide only with dogmas +but yield readily to the magic of religious feelings; it is a source of +pain to them to let the latter go simply on account of the +former.--Scientific philosophy must be very much on its guard lest on +account of this necessity--an evolved and hence, also, a transitory +necessity--delusions are smuggled in. Even logicians speak of +"presentiments" of truth in ethics and in art (for example of the +presentiment that the essence of things is unity) a thing which, +nevertheless, ought to be prohibited. Between carefully deduced truths +and such "foreboded" things there lies the abysmal distinction that the +former are products of the intellect and the latter of the necessity. +Hunger is no evidence that there is food at hand to appease it. Hunger +merely craves food. "Presentiment" does not denote that the existence of +a thing is known in any way whatever. It denotes merely that it is +deemed possible to the extent that it is desired or feared. The +"presentiment" is not one step forward in the domain of certainty.--It +is involuntarily believed that the religious tinted sections of a +philosophy are better attested than the others, but the case is at +bottom just the opposite: there is simply the inner wish that it may be +so, that the thing which beautifies may also be true. This wish leads us +to accept bad grounds as good. + + +132 + +=Of the Christian Need of Salvation.=--Careful consideration must render +it possible to propound some explanation of that process in the soul of +a Christian which is termed need of salvation, and to propound an +explanation, too, free from mythology: hence one purely psychological. +Heretofore psychological explanations of religious conditions and +processes have really been in disrepute, inasmuch as a theology calling +itself free gave vent to its unprofitable nature in this domain; for its +principal aim, so far as may be judged from the spirit of its creator, +Schleier-macher, was the preservation of the Christian religion and the +maintenance of the Christian theology. It appeared that in the +psychological analysis of religious "facts" a new anchorage and above +all a new calling were to be gained. Undisturbed by such predecessors, +we venture the following exposition of the phenomena alluded to. Man is +conscious of certain acts which are very firmly implanted in the general +course of conduct: indeed he discovers in himself a predisposition to +such acts that seems to him to be as unalterable as his very being. How +gladly he would essay some other kind of acts which in the general +estimate of conduct are rated the best and highest, how gladly he would +welcome the consciousness of well doing which ought to follow unselfish +motive! Unfortunately, however, it goes no further than this longing: +the discontent consequent upon being unable to satisfy it is added to +all other kinds of discontent which result from his life destiny in +particular or which may be due to so called bad acts; so that a deep +depression ensues accompanied by a desire for some physician to remove +it and all its causes.--This condition would not be found so bitter if +the individual but compared himself freely with other men: for then he +would have no reason to be discontented with himself in particular as he +is merely bearing his share of the general burden of human discontent +and incompleteness. But he compares himself with a being who alone must +be capable of the conduct that is called unegoistic and of an enduring +consciousness of unselfish motive, with God. It is because he gazes into +this clear mirror, that his own self seems so extraordinarily distracted +and so troubled. Thereupon the thought of that being, in so far as it +flits before his fancy as retributive justice, occasions him anxiety. In +every conceivable small and great experience he believes he sees the +anger of the being, his threats, the very implements and manacles of his +judge and prison. What succors him in this danger, which, in the +prospect of an eternal duration of punishment, transcends in hideousness +all the horrors that can be presented to the imagination? + + +133 + +Before we consider this condition in its further effects, we would admit +to ourselves that man is betrayed into this condition not through his +"fault" and "sin" but through a series of delusions of the reason; that +it was the fault of the mirror if his own self appeared to him in the +highest degree dark and hateful, and that that mirror was his own work, +the very imperfect work of human imagination and judgment. In the first +place a being capable of absolutely unegoistic conduct is as fabulous as +the phoenix. Such a being is not even thinkable for the very reason that +the whole notion of "unegoistic conduct," when closely examined, +vanishes into air. Never yet has a man done anything solely for others +and entirely without reference to a personal motive; indeed how could he +possibly do anything that had no reference to himself, that is without +inward compulsion (which must always have its basis in a personal need)? +How could the ego act without ego?--A god, who, on the other hand, is +all love, as he is usually represented, would not be capable of a +solitary unegoistic act: whence one is reminded of a reflection of +Lichtenberg's which is, in truth, taken from a lower sphere: "We cannot +possibly feel for others, as the expression goes; we feel only for +ourselves. The assertion sounds hard, but it is not, if rightly +understood. A man loves neither his father nor his mother nor his wife +nor his child, but simply the feelings which they inspire." Or, as La +Rochefoucauld says: "If you think you love your mistress for the mere +love of her, you are very much mistaken." Why acts of love are more +highly prized than others, namely not on account of their nature, but on +account of their utility, has already been explained in the section on +the origin of moral feelings. But if a man should wish to be all love +like the god aforesaid, and want to do all things for others and nothing +for himself, the procedure would be fundamentally impossible because he +_must_ do a great deal for himself before there would be any possibility +of doing anything for the love of others. It is also essential that +others be sufficiently egoistic to accept always and at all times this +self sacrifice and living for others, so that the men of love and self +sacrifice have an interest in the survival of unloving and selfish +egoists, while the highest morality, in order to maintain itself must +formally enforce the existence of immorality (wherein it would be really +destroying itself.)--Further: the idea of a god perturbs and discourages +as long as it is accepted but as to how it originated can no longer, in +the present state of comparative ethnological science, be a matter of +doubt, and with the insight into the origin of this belief all faith +collapses. What happens to the Christian who compares his nature with +that of God is exactly what happened to Don Quixote, who depreciated his +own prowess because his head was filled with the wondrous deeds of the +heroes of chivalrous romance. The standard of measurement which both +employ belongs to the domain of fable.--But if the idea of God +collapses, so too, does the feeling of "sin" as a violation of divine +rescript, as a stain upon a god-like creation. There still apparently +remains that discouragement which is closely allied with fear of the +punishment of worldly justice or of the contempt of one's fellow men. +The keenest thorn in the sentiment of sin is dulled when it is perceived +that one's acts have contravened human tradition, human rules and human +laws without having thereby endangered the "eternal salvation of the +soul" and its relations with deity. If finally men attain to the +conviction of the absolute necessity of all acts and of their utter +irresponsibility and then absorb it into their flesh and blood, every +relic of conscience pangs will disappear. + + +134 + +If now, as stated, the Christian, through certain delusive feelings, is +betrayed into self contempt, that is by a false and unscientific view of +his acts and feelings, he must, nevertheless, perceive with the utmost +amazement that this state of self contempt, of conscience pangs, of +despair in particular, does not last, that there are hours during which +all these things are wafted away from the soul and he feels himself once +more free and courageous. The truth is that joy in his own being, the +fulness of his own powers in connection with the inevitable decline of +his profound excitation with the lapse of time, bore off the palm of +victory. The man loves himself once more, he feels it--but this very new +love, this new self esteem seems to him incredible. He can see in it +only the wholly unmerited stream of the light of grace shed down upon +him. If he formerly saw in every event merely warnings, threats, +punishments and every kind of indication of divine anger, he now reads +into his experiences the grace of god. The latter circumstance seems to +him full of love, the former as a helpful pointing of the way, and his +entirely joyful frame of mind now seems to him to be an absolute proof +of the goodness of God. As formerly in his states of discouragement he +interpreted his conduct falsely so now he does the same with his +experiences. His state of consolation is now regarded as the effect +produced by some external power. The love with which, at bottom, he +loves himself, seems to be the divine love. That which he calls grace +and the preliminary of salvation is in reality self-grace, +self-salvation. + + +135 + +Therefore a certain false psychology, a certain kind of imaginativeness +in the interpretation of motives and experiences is the essential +preliminary to being a Christian and to experiencing the need of +salvation. Upon gaining an insight into this wandering of the reason and +the imagination, one ceases to be a Christian. + + +136 + +=Of Christian Asceticism and Sanctity.=--Much as some thinkers have +exerted themselves to impart an air of the miraculous to those singular +phenomena known as asceticism and sanctity, to question which or to +account for which upon a rational basis would be wickedness and +sacrilege, the temptation to this wickedness is none the less great. A +powerful impulse of nature has in every age led to protest against such +phenomena. At any rate science, inasmuch as it is the imitation of +nature, permits the casting of doubts upon the inexplicable character +and the supernal degree of such phenomena. It is true that heretofore +science has not succeeded in its attempts at explanation. The phenomena +remain unexplained still, to the great satisfaction of those who revere +moral miracles. For, speaking generally, the unexplained must rank as +the inexplicable, the inexplicable as the non-natural, supernatural, +miraculous--so runs the demand in the souls of all the religious and all +the metaphysicians (even the artists if they happen to be thinkers), +whereas the scientific man sees in this demand the "evil +principle."--The universal, first, apparent truth that is encountered in +the contemplation of sanctity and asceticism is that their nature is +complicated; for nearly always, within the physical world as well as in +the moral, the apparently miraculous may be traced successfully to the +complex, the obscure, the multi-conditioned. Let us venture then to +isolate a few impulses in the soul of the saint and the ascetic, to +consider them separately and then view them as a synthetic development. + + +137 + +There is an obstinacy against oneself, certain sublimated forms of which +are included in asceticism. Certain kinds of men are under such a strong +necessity of exercising their power and dominating impulses that, if +other objects are lacking or if they have not succeeded with other +objects they will actually tyrannize over some portions of their own +nature or over sections and stages of their own personality. Thus do +many thinkers bring themselves to views which are far from likely to +increase or improve their fame. Many deliberately bring down the +contempt of others upon themselves although they could easily have +retained consideration by silence. Others contradict earlier opinions +and do not shrink from the ordeal of being deemed inconsistent. On the +contrary they strive for this and act like eager riders who enjoy +horseback exercise most when the horse is skittish. Thus will men in +dangerous paths ascend to the highest steeps in order to laugh to scorn +their own fear and their own trembling limbs. Thus will the philosopher +embrace the dogmas of asceticism, humility, sanctity, in the light of +which his own image appears in its most hideous aspect. This crushing of +self, this mockery of one's own nature, this spernere se sperni out of +which religions have made so much is in reality but a very high +development of vanity. The whole ethic of the sermon on the mount +belongs in this category: man has a true delight in mastering himself +through exaggerated pretensions or excessive expedients and later +deifying this tyrannically exacting something within him. In every +scheme of ascetic ethics, man prays to one part of himself as if it were +god and hence it is necessary for him to treat the rest of himself as +devil. + + +138 + +=Man is Not at All Hours Equally Moral=; this is established. If one's +morality be judged according to one's capacity for great, self +sacrificing resolutions and abnegations (which when continual, and made +a habit are known as sanctity) one is, in affection, or disposition, the +most moral: while higher excitement supplies wholly new impulses which, +were one calm and cool as ordinarily, one would not deem oneself even +capable of. How comes this? Apparently from the propinquity of all great +and lofty emotional states. If a man is brought to an extraordinary +pitch of feeling he can resolve upon a fearful revenge or upon a fearful +renunciation of his thirst for vengeance indifferently. He craves, under +the influences of powerful emotion, the great, the powerful, the +immense, and if he chances to perceive that the sacrifice of himself +will afford him as much satisfaction as the sacrifice of another, or +will afford him more, he will choose self sacrifice. What concerns him +particularly is simply the unloading of his emotion. Hence he readily, +to relieve his tension, grasps the darts of the enemy and buries them in +his own breast. That in self abnegation and not in revenge the element +of greatness consisted must have been brought home to mankind only after +long habituation. A god who sacrifices himself would be the most +powerful and most effective symbol of this sort of greatness. As the +conquest of the most hardly conquered enemy, the sudden mastering of a +passion--thus does such abnegation _appear_: hence it passes for the +summit of morality. In reality all that is involved is the exchange of +one idea for another whilst the temperament remained at a like altitude, +a like tidal state. Men when coming out of the spell, or resting from +such passionate excitation, no longer understand the morality of such +instants, but the admiration of all who participated in the occasion +sustains them. Pride is their support if the passion and the +comprehension of their act weaken. Therefore, at bottom even such acts +of self-abnegation are not moral inasmuch as they are not done with a +strict regard for others. Rather do others afford the high strung +temperament an opportunity to lighten itself through such abnegation. + + +139 + +=Even the Ascetic Seeks to Make Life Easier=, and generally by means of +absolute subjection to another will or to an all inclusive rule and +ritual, pretty much as the Brahmin leaves absolutely nothing to his own +volition but is guided in every moment of his life by some holy +injunction or other. This subjection is a potent means of acquiring +dominion over oneself. One is occupied, hence time does not bang heavy +and there is no incitement of the personal will and of the individual +passion. The deed once done there is no feeling of responsibility nor +the sting of regret. One has given up one's own will once for all and +this is easier than to give it up occasionally, as it is also easier +wholly to renounce a desire than to yield to it in measured degree. When +we consider the present relation of man to the state we perceive +unconditional obedience is easier than conditional. The holy person also +makes his lot easier through the complete surrender of his life +personality and it is all delusion to admire such a phenomenon as the +loftiest heroism of morality. It is always more difficult to assert +one's personality without shrinking and without hesitation than to give +it up altogether in the manner indicated, and it requires moreover more +intellect and thought. + + +140 + +After having discovered in many of the less comprehensible actions mere +manifestations of pleasure in emotion for its own sake, I fancy I can +detect in the self contempt which characterises holy persons, and also +in their acts of self torture (through hunger and scourgings, +distortions and chaining of the limbs, acts of madness) simply a means +whereby such natures may resist the general exhaustion of their will to +live (their nerves). They employ the most painful expedients to escape +if only for a time from the heaviness and weariness in which they are +steeped by their great mental indolence and their subjection to a will +other than their own. + + +141 + +=The Most Usual Means= by which the ascetic and the sanctified +individual seeks to make life more endurable comprises certain combats +of an inner nature involving alternations of victory and prostration. +For this purpose an enemy is necessary and he is found in the so called +"inner enemy." That is, the holy individual makes use of his tendency to +vanity, domineering and pride, and of his mental longings in order to +contemplate his life as a sort of continuous battle and himself as a +battlefield, in which good and evil spirits wage war with varying +fortune. It is an established fact that the imagination is restrained +through the regularity and adequacy of sexual intercourse while on the +other hand abstention from or great irregularity in sexual intercourse +will cause the imagination to run riot. The imaginations of many of the +Christian saints were obscene to a degree; and because of the theory +that sexual desires were in reality demons that raged within them, the +saints did not feel wholly responsible for them. It is to this +conviction that we are indebted for the highly instructive sincerity of +their evidence against themselves. It was to their interest that this +contest should always be kept up in some fashion because by means of +this contest, as already stated, their empty lives gained distraction. +In order that the contest might seem sufficiently great to inspire +sympathy and admiration in the unsanctified, it was essential that +sexual capacity be ever more and more damned and denounced. Indeed the +danger of eternal damnation was so closely allied to this capacity that +for whole generations Christians showed their children with actual +conscience pangs. What evil may not have been done to humanity through +this! And yet here the truth is just upside down: an exceedingly +unseemly attitude for the truth. Christianity, it is true, had said that +every man is conceived and born in sin, and in the intolerable and +excessive Christianity of Calderon this thought is again perverted and +entangled into the most distorted paradox extant in the well known lines + + The greatest sin of man + Is the sin of being born. + +In all pessimistic religions the act of procreation is looked upon as +evil in itself. This is far from being the general human opinion. It is +not even the opinion of all pessimists. Empedocles, for example, knows +nothing of anything shameful, devilish and sinful in it. He sees rather +in the great field of bliss of unholiness simply a healthful and hopeful +phenomenon, Aphrodite. She is to him an evidence that strife does not +always rage but that some time a gentle demon is to wield the sceptre. +The Christian pessimists of practice, had, as stated, a direct interest +in the prevalence of an opposite belief. They needed in the loneliness +and the spiritual wilderness of their lives an ever living enemy, and a +universally known enemy through whose conquest they might appear to the +unsanctified as utterly incomprehensible and half unnatural beings. When +this enemy at last, as a result of their mode of life and their +shattered health, took flight forever, they were able immediately to +people their inner selves with new demons. The rise and fall of the +balance of cheerfulness and despair maintained their addled brains in a +totally new fluctuation of longing and peace of soul. And in that period +psychology served not only to cast suspicion on everything human but to +wound and scourge it, to crucify it. Man wanted to find himself as base +and evil as possible. Man sought to become anxious about the state of +his soul, he wished to be doubtful of his own capacity. Everything +natural with which man connects the idea of badness and sinfulness (as, +for instance, is still customary in regard to the erotic) injures and +degrades the imagination, occasions a shamed aspect, leads man to war +upon himself and makes him uncertain, distrustful of himself. Even his +dreams acquire a tincture of the unclean conscience. And yet this +suffering because of the natural element in certain things is wholly +superfluous. It is simply the result of opinions regarding the things. +It is easy to understand why men become worse than they are if they are +brought to look upon the unavoidably natural as bad and later to feel it +as of evil origin. It is the master stroke of religions and metaphysics +that wish to make man out bad and sinful by nature, to render nature +suspicious in his eyes and to so make himself evil, for he learns to +feel himself evil when he cannot divest himself of nature. He gradually +comes to look upon himself, after a long life lived naturally, so +oppressed by a weight of sin that supernatural powers become necessary +to relieve him of the burden; and with this notion comes the so called +need of salvation, which is the result not of a real but of an imaginary +sinfulness. Go through the separate moral expositions in the vouchers of +christianity and it will always be found that the demands are excessive +in order that it may be impossible for man to satisfy them. The object +is not that he may become moral but that he may feel as sinful as +possible. If this feeling had not been rendered agreeable to man--why +should he have improvised such an ideal and clung to it so long? As in +the ancient world an incalculable strength of intellect and capacity for +feeling was squandered in order to increase the joy of living through +feastful systems of worship, so in the era of christianity an equally +incalculable quantity of intellectual capacity has been sacrificed in +another endeavor: that man should in every way feel himself sinful and +thereby be moved, inspired, inspirited. To move, to inspire, to inspirit +at any cost--is not this the freedom cry of an exhausted, over-ripe, +over cultivated age? The circle of all the natural sensations had been +gone through a hundred times: the soul had grown weary. Then the saints +and the ascetics found a new order of ecstacies. They set themselves +before the eyes of all not alone as models for imitation to many, but as +fearful and yet delightful spectacles on the boundary line between this +world and the next world, where in that period everyone thought he saw +at one time rays of heavenly light, at another fearful, threatening +tongues of flame. The eye of the saint, directed upon the fearful +significance of the shortness of earthly life, upon the imminence of the +last judgment, upon eternal life hereafter; this glowering eye in an +emaciated body caused men, in the old time world, to tremble to the +depths of their being. To look, to look away and shudder, to feel anew +the fascination of the spectacle, to yield to it, sate oneself upon it +until the soul trembled with ardor and fever--that was the last pleasure +left to classical antiquity when its sensibilities had been blunted by +the arena and the gladiatorial show. + + +142 + +=To Sum Up All That Has Been Said=: that condition of soul at which the +saint or expectant saint is rejoiced is a combination of elements which +we are all familiar with, except that under other influences than those +of mere religious ideation they customarily arouse the censure of men in +the same way that when combined with religion itself and regarded as the +supreme attainment of sanctity, they are object of admiration and even +of prayer--at least in more simple times. Very soon the saint turns upon +himself that severity that is so closely allied to the instinct of +domination at any price and which inspire even in the most solitary +individual the sense of power. Soon his swollen sensitiveness of feeling +breaks forth from the longing to restrain his passions within it and is +transformed into a longing to master them as if they were wild steeds, +the master impulse being ever that of a proud spirit; next he craves a +complete cessation of all perturbing, fascinating feelings, a waking +sleep, an enduring repose in the lap of a dull, animal, plant-like +indolence. Next he seeks the battle and extinguishes it within himself +because weariness and boredom confront him. He binds his +self-deification with self-contempt. He delights in the wild tumult of +his desires and the sharp pain of sin, in the very idea of being lost. +He is able to play his very passions, for instance the desire to +domineer, a trick so that he goes to the other extreme of abject +humiliation and subjection, so that his overwrought soul is without any +restraint through this antithesis. And, finally, when indulgence in +visions, in talks with the dead or with divine beings overcomes him, +this is really but a form of gratification that he craves, perhaps a +form of gratification in which all other gratifications are blended. +Novalis, one of the authorities in matters of sanctity, because of his +experience and instinct, betrays the whole secret with the utmost +simplicity when he says: "It is remarkable that the close connection of +gratification, religion and cruelty has not long ago made men aware of +their inner relationship and common tendency." + + +143 + +=Not What the Saint is but what he was in= the eyes of the +non-sanctified gives him his historical importance. Because there +existed a delusion respecting the saint, his soul states being falsely +viewed and his personality being sundered as much as possible from +humanity as a something incomparable and supernatural, because of these +things he attained the extraordinary with which he swayed the +imaginations of whole nations and whole ages. Even he knew himself not +for even he regarded his dispositions, passions and actions in +accordance with a system of interpretation as artificial and exaggerated +as the pneumatic interpretation of the bible. The distorted and diseased +in his own nature with its blending of spiritual poverty, defective +knowledge, ruined health, overwrought nerves, remained as hidden from +his view as from the view of his beholders. He was neither a +particularly good man nor a particularly bad man but he stood for +something that was far above the human standard in wisdom and goodness. +Faith in him sustained faith in the divine and miraculous, in a +religious significance of all existence, in an impending day of +judgment. In the last rays of the setting sun of the ancient world, +which fell upon the christian peoples, the shadowy form of the saint +attained enormous proportions--to such enormous proportions, indeed, +that down even to our own age, which no longer believes in god, there +are thinkers who believe in the saints. + + +144 + +It stands to reason that this sketch of the saint, made upon the model +of the whole species, can be confronted with many opposing sketches that +would create a more agreeable impression. There are certain exceptions +among the species who distinguish themselves either by especial +gentleness or especial humanity, and perhaps by the strength of their +own personality. Others are in the highest degree fascinating because +certain of their delusions shed a particular glow over their whole +being, as is the case with the founder of christianity who took himself +for the only begotten son of God and hence felt himself sinless; so that +through his imagination--that should not be too harshly judged since the +whole of antiquity swarmed with sons of god--he attained the same goal, +the sense of complete sinlessness, complete irresponsibility, that can +now be attained by every individual through science.--In the same manner +I have viewed the saints of India who occupy an intermediate station +between the christian saints and the Greek philosophers and hence are +not to be regarded as a pure type. Knowledge and science--as far as they +existed--and superiority to the rest of mankind by logical discipline +and training of the intellectual powers were insisted upon by the +Buddhists as essential to sanctity, just as they were denounced by the +christian world as the indications of sinfulness. \ No newline at end of file diff --git a/mla/ensemble/__init__.py b/mla/ensemble/__init__.py new file mode 100644 index 0000000..bf3c9c0 --- /dev/null +++ b/mla/ensemble/__init__.py @@ -0,0 +1,2 @@ +# coding:utf-8 +from .random_forest import RandomForestClassifier, RandomForestRegressor diff --git a/mla/ensemble/base.py b/mla/ensemble/base.py new file mode 100644 index 0000000..c1a97fb --- /dev/null +++ b/mla/ensemble/base.py @@ -0,0 +1,65 @@ +# coding:utf-8 +import numpy as np +from scipy import stats + + +def f_entropy(p): + # Convert values to probability + p = np.bincount(p) / float(p.shape[0]) + + ep = stats.entropy(p) + if ep == -float("inf"): + return 0.0 + return ep + + +def information_gain(y, splits): + splits_entropy = sum( + [f_entropy(split) * (float(split.shape[0]) / y.shape[0]) for split in splits] + ) + return f_entropy(y) - splits_entropy + + +def mse_criterion(y, splits): + y_mean = np.mean(y) + return -sum( + [ + np.sum((split - y_mean) ** 2) * (float(split.shape[0]) / y.shape[0]) + for split in splits + ] + ) + + +def xgb_criterion(y, left, right, loss): + left = loss.gain(left["actual"], left["y_pred"]) + right = loss.gain(right["actual"], right["y_pred"]) + initial = loss.gain(y["actual"], y["y_pred"]) + gain = left + right - initial + return gain + + +def get_split_mask(X, column, value): + left_mask = X[:, column] < value + right_mask = X[:, column] >= value + return left_mask, right_mask + + +def split(X, y, value): + left_mask = X < value + right_mask = X >= value + return y[left_mask], y[right_mask] + + +def split_dataset(X, target, column, value, return_X=True): + left_mask, right_mask = get_split_mask(X, column, value) + + left, right = {}, {} + for key in target.keys(): + left[key] = target[key][left_mask] + right[key] = target[key][right_mask] + + if return_X: + left_X, right_X = X[left_mask], X[right_mask] + return left_X, right_X, left, right + else: + return left, right diff --git a/mla/ensemble/gbm.py b/mla/ensemble/gbm.py new file mode 100644 index 0000000..58fbff3 --- /dev/null +++ b/mla/ensemble/gbm.py @@ -0,0 +1,152 @@ +# coding:utf-8 +import numpy as np + +# logistic function +from scipy.special import expit + +from mla.base import BaseEstimator +from mla.ensemble.base import mse_criterion +from mla.ensemble.tree import Tree + +""" +References: +https://arxiv.org/pdf/1603.02754v3.pdf +http://www.saedsayad.com/docs/xgboost.pdf +https://homes.cs.washington.edu/~tqchen/pdf/BoostedTree.pdf +http://stats.stackexchange.com/questions/202858/loss-function-approximation-with-taylor-expansion +""" + + +class Loss: + """Base class for loss functions.""" + + def __init__(self, regularization=1.0): + self.regularization = regularization + + def grad(self, actual, predicted): + """First order gradient.""" + raise NotImplementedError() + + def hess(self, actual, predicted): + """Second order gradient.""" + raise NotImplementedError() + + def approximate(self, actual, predicted): + """Approximate leaf value.""" + return self.grad(actual, predicted).sum() / ( + self.hess(actual, predicted).sum() + self.regularization + ) + + def transform(self, pred): + """Transform predictions values.""" + return pred + + def gain(self, actual, predicted): + """Calculate gain for split search.""" + nominator = self.grad(actual, predicted).sum() ** 2 + denominator = self.hess(actual, predicted).sum() + self.regularization + return 0.5 * (nominator / denominator) + + +class LeastSquaresLoss(Loss): + """Least squares loss""" + + def grad(self, actual, predicted): + return actual - predicted + + def hess(self, actual, predicted): + return np.ones_like(actual) + + +class LogisticLoss(Loss): + """Logistic loss.""" + + def grad(self, actual, predicted): + return actual * expit(-actual * predicted) + + def hess(self, actual, predicted): + expits = expit(predicted) + return expits * (1 - expits) + + def transform(self, output): + # Apply logistic (sigmoid) function to the output + return expit(output) + + +class GradientBoosting(BaseEstimator): + """Gradient boosting trees with Taylor's expansion approximation (as in xgboost).""" + + def __init__( + self, + n_estimators, + learning_rate=0.1, + max_features=10, + max_depth=2, + min_samples_split=10, + ): + self.min_samples_split = min_samples_split + self.learning_rate = learning_rate + self.max_depth = max_depth + self.max_features = max_features + self.n_estimators = n_estimators + self.trees = [] + self.loss = None + + def fit(self, X, y=None): + self._setup_input(X, y) + self.y_mean = np.mean(y) + self._train() + + def _train(self): + # Initialize model with zeros + y_pred = np.zeros(self.n_samples, np.float32) + # Or mean + # y_pred = np.full(self.n_samples, self.y_mean) + + for n in range(self.n_estimators): + residuals = self.loss.grad(self.y, y_pred) + tree = Tree(regression=True, criterion=mse_criterion) + # Pass multiple target values to the tree learner + targets = { + # Residual values + "y": residuals, + # Actual target values + "actual": self.y, + # Predictions from previous step + "y_pred": y_pred, + } + tree.train( + self.X, + targets, + max_features=self.max_features, + min_samples_split=self.min_samples_split, + max_depth=self.max_depth, + loss=self.loss, + ) + predictions = tree.predict(self.X) + y_pred += self.learning_rate * predictions + self.trees.append(tree) + + def _predict(self, X=None): + y_pred = np.zeros(X.shape[0], np.float32) + + for i, tree in enumerate(self.trees): + y_pred += self.learning_rate * tree.predict(X) + return y_pred + + def predict(self, X=None): + return self.loss.transform(self._predict(X)) + + +class GradientBoostingRegressor(GradientBoosting): + def fit(self, X, y=None): + self.loss = LeastSquaresLoss() + super(GradientBoostingRegressor, self).fit(X, y) + + +class GradientBoostingClassifier(GradientBoosting): + def fit(self, X, y=None): + # Convert labels from {0, 1} to {-1, 1} + y = (y * 2) - 1 + self.loss = LogisticLoss() + super(GradientBoostingClassifier, self).fit(X, y) diff --git a/mla/ensemble/random_forest.py b/mla/ensemble/random_forest.py new file mode 100644 index 0000000..57eddf3 --- /dev/null +++ b/mla/ensemble/random_forest.py @@ -0,0 +1,130 @@ +# coding:utf-8 +import numpy as np + +from mla.base import BaseEstimator +from mla.ensemble.base import information_gain, mse_criterion +from mla.ensemble.tree import Tree + + +class RandomForest(BaseEstimator): + def __init__( + self, + n_estimators=10, + max_features=None, + min_samples_split=10, + max_depth=None, + criterion=None, + ): + """Base class for RandomForest. + + Parameters + ---------- + n_estimators : int + The number of decision tree. + max_features : int + The number of features to consider when looking for the best split. + min_samples_split : int + The minimum number of samples required to split an internal node. + max_depth : int + Maximum depth of the tree. + criterion : str + The function to measure the quality of a split. + """ + self.max_depth = max_depth + self.min_samples_split = min_samples_split + self.max_features = max_features + self.n_estimators = n_estimators + self.trees = [] + + def fit(self, X, y): + self._setup_input(X, y) + if self.max_features is None: + self.max_features = int(np.sqrt(X.shape[1])) + else: + assert X.shape[1] > self.max_features + self._train() + + def _train(self): + for tree in self.trees: + tree.train( + self.X, + self.y, + max_features=self.max_features, + min_samples_split=self.min_samples_split, + max_depth=self.max_depth, + ) + + def _predict(self, X=None): + raise NotImplementedError() + + +class RandomForestClassifier(RandomForest): + def __init__( + self, + n_estimators=10, + max_features=None, + min_samples_split=10, + max_depth=None, + criterion="entropy", + ): + super(RandomForestClassifier, self).__init__( + n_estimators=n_estimators, + max_features=max_features, + min_samples_split=min_samples_split, + max_depth=max_depth, + criterion=criterion, + ) + + if criterion == "entropy": + self.criterion = information_gain + else: + raise ValueError() + + # Initialize empty trees + for _ in range(self.n_estimators): + self.trees.append(Tree(criterion=self.criterion)) + + def _predict(self, X=None): + y_shape = np.unique(self.y).shape[0] + predictions = np.zeros((X.shape[0], y_shape)) + + for i in range(X.shape[0]): + row_pred = np.zeros(y_shape) + for tree in self.trees: + row_pred += tree.predict_row(X[i, :]) + + row_pred /= self.n_estimators + predictions[i, :] = row_pred + return predictions + + +class RandomForestRegressor(RandomForest): + def __init__( + self, + n_estimators=10, + max_features=None, + min_samples_split=10, + max_depth=None, + criterion="mse", + ): + super(RandomForestRegressor, self).__init__( + n_estimators=n_estimators, + max_features=max_features, + min_samples_split=min_samples_split, + max_depth=max_depth, + ) + + if criterion == "mse": + self.criterion = mse_criterion + else: + raise ValueError() + + # Initialize empty regression trees + for _ in range(self.n_estimators): + self.trees.append(Tree(regression=True, criterion=self.criterion)) + + def _predict(self, X=None): + predictions = np.zeros((X.shape[0], self.n_estimators)) + for i, tree in enumerate(self.trees): + predictions[:, i] = tree.predict(X) + return predictions.mean(axis=1) diff --git a/mla/ensemble/tree.py b/mla/ensemble/tree.py new file mode 100644 index 0000000..3e6ae6f --- /dev/null +++ b/mla/ensemble/tree.py @@ -0,0 +1,206 @@ +# coding:utf-8 +import random + +import numpy as np +from scipy import stats + +from mla.ensemble.base import split, split_dataset, xgb_criterion + +random.seed(111) + + +class Tree(object): + """Recursive implementation of decision tree.""" + + def __init__(self, regression=False, criterion=None, n_classes=None): + self.regression = regression + self.impurity = None + self.threshold = None + self.column_index = None + self.outcome = None + self.criterion = criterion + self.loss = None + self.n_classes = n_classes # Only for classification + + self.left_child = None + self.right_child = None + + @property + def is_terminal(self): + return not bool(self.left_child and self.right_child) + + def _find_splits(self, X): + """Find all possible split values.""" + split_values = set() + + # Get unique values in a sorted order + x_unique = list(np.unique(X)) + for i in range(1, len(x_unique)): + # Find a point between two values + average = (x_unique[i - 1] + x_unique[i]) / 2.0 + split_values.add(average) + + return list(split_values) + + def _find_best_split(self, X, target, n_features): + """Find best feature and value for a split. Greedy algorithm.""" + + # Sample random subset of features + subset = random.sample(list(range(0, X.shape[1])), n_features) + max_gain, max_col, max_val = None, None, None + + for column in subset: + split_values = self._find_splits(X[:, column]) + for value in split_values: + if self.loss is None: + # Random forest + splits = split(X[:, column], target["y"], value) + gain = self.criterion(target["y"], splits) + else: + # Gradient boosting + left, right = split_dataset( + X, target, column, value, return_X=False + ) + gain = xgb_criterion(target, left, right, self.loss) + + if (max_gain is None) or (gain > max_gain): + max_col, max_val, max_gain = column, value, gain + return max_col, max_val, max_gain + + def _train( + self, + X, + target, + max_features=None, + min_samples_split=10, + max_depth=None, + minimum_gain=0.01, + ): + try: + # Exit from recursion using assert syntax + assert X.shape[0] > min_samples_split + assert max_depth > 0 + + if max_features is None: + max_features = X.shape[1] + + column, value, gain = self._find_best_split(X, target, max_features) + assert gain is not None + if self.regression: + assert gain != 0 + else: + assert gain > minimum_gain + + self.column_index = column + self.threshold = value + self.impurity = gain + + # Split dataset + left_X, right_X, left_target, right_target = split_dataset( + X, target, column, value + ) + + # Grow left and right child + self.left_child = Tree(self.regression, self.criterion, self.n_classes) + self.left_child._train( + left_X, + left_target, + max_features, + min_samples_split, + max_depth - 1, + minimum_gain, + ) + + self.right_child = Tree(self.regression, self.criterion, self.n_classes) + self.right_child._train( + right_X, + right_target, + max_features, + min_samples_split, + max_depth - 1, + minimum_gain, + ) + except AssertionError: + self._calculate_leaf_value(target) + + def train( + self, + X, + target, + max_features=None, + min_samples_split=10, + max_depth=None, + minimum_gain=0.01, + loss=None, + ): + """Build a decision tree from training set. + + Parameters + ---------- + + X : array-like + Feature dataset. + target : dictionary or array-like + Target values. + max_features : int or None + The number of features to consider when looking for the best split. + min_samples_split : int + The minimum number of samples required to split an internal node. + max_depth : int + Maximum depth of the tree. + minimum_gain : float, default 0.01 + Minimum gain required for splitting. + loss : function, default None + Loss function for gradient boosting. + """ + + if not isinstance(target, dict): + target = {"y": target} + + # Loss for gradient boosting + if loss is not None: + self.loss = loss + + if not self.regression: + self.n_classes = len(np.unique(target["y"])) + + self._train( + X, + target, + max_features=max_features, + min_samples_split=min_samples_split, + max_depth=max_depth, + minimum_gain=minimum_gain, + ) + + def _calculate_leaf_value(self, targets): + """Find optimal value for leaf.""" + if self.loss is not None: + # Gradient boosting + self.outcome = self.loss.approximate(targets["actual"], targets["y_pred"]) + else: + # Random Forest + if self.regression: + # Mean value for regression task + self.outcome = np.mean(targets["y"]) + else: + # Probability for classification task + self.outcome = ( + np.bincount(targets["y"], minlength=self.n_classes) + / targets["y"].shape[0] + ) + + def predict_row(self, row): + """Predict single row.""" + if not self.is_terminal: + if row[self.column_index] < self.threshold: + return self.left_child.predict_row(row) + else: + return self.right_child.predict_row(row) + return self.outcome + + def predict(self, X): + result = np.zeros(X.shape[0]) + for i in range(X.shape[0]): + result[i] = self.predict_row(X[i, :]) + return result diff --git a/mla/fm.py b/mla/fm.py new file mode 100644 index 0000000..6e1c142 --- /dev/null +++ b/mla/fm.py @@ -0,0 +1,90 @@ +# coding:utf-8 + +import autograd.numpy as np +from autograd import elementwise_grad + +from mla.base import BaseEstimator +from mla.metrics import mean_squared_error, binary_crossentropy + + +np.random.seed(9999) + +""" +References: +Factorization Machines http://www.csie.ntu.edu.tw/~b97053/paper/Rendle2010FM.pdf +""" + + +class BaseFM(BaseEstimator): + def __init__( + self, + n_components=10, + max_iter=100, + init_stdev=0.1, + learning_rate=0.01, + reg_v=0.1, + reg_w=0.5, + reg_w0=0.0, + ): + """Simplified factorization machines implementation using SGD optimizer.""" + self.reg_w0 = reg_w0 + self.reg_w = reg_w + self.reg_v = reg_v + self.n_components = n_components + self.lr = learning_rate + self.init_stdev = init_stdev + self.max_iter = max_iter + self.loss = None + self.loss_grad = None + + def fit(self, X, y=None): + self._setup_input(X, y) + # bias + self.wo = 0.0 + # Feature weights + self.w = np.zeros(self.n_features) + # Factor weights + self.v = np.random.normal( + scale=self.init_stdev, size=(self.n_features, self.n_components) + ) + self._train() + + def _train(self): + for epoch in range(self.max_iter): + y_pred = self._predict(self.X) + loss = self.loss_grad(self.y, y_pred) + w_grad = np.dot(loss, self.X) / float(self.n_samples) + self.wo -= self.lr * (loss.mean() + 2 * self.reg_w0 * self.wo) + self.w -= self.lr * w_grad + (2 * self.reg_w * self.w) + self._factor_step(loss) + + def _factor_step(self, loss): + for ix, x in enumerate(self.X): + for i in range(self.n_features): + v_grad = loss[ix] * (x.dot(self.v).dot(x[i])[0] - self.v[i] * x[i] ** 2) + self.v[i] -= self.lr * v_grad + (2 * self.reg_v * self.v[i]) + + def _predict(self, X=None): + linear_output = np.dot(X, self.w) + factors_output = ( + np.sum(np.dot(X, self.v) ** 2 - np.dot(X**2, self.v**2), axis=1) / 2.0 + ) + return self.wo + linear_output + factors_output + + +class FMRegressor(BaseFM): + def fit(self, X, y=None): + super(FMRegressor, self).fit(X, y) + self.loss = mean_squared_error + self.loss_grad = elementwise_grad(mean_squared_error) + + +class FMClassifier(BaseFM): + def fit(self, X, y=None): + super(FMClassifier, self).fit(X, y) + self.loss = binary_crossentropy + self.loss_grad = elementwise_grad(binary_crossentropy) + + def predict(self, X=None): + predictions = self._predict(X) + return np.sign(predictions) diff --git a/mla/gaussian_mixture.py b/mla/gaussian_mixture.py new file mode 100644 index 0000000..8ab82fb --- /dev/null +++ b/mla/gaussian_mixture.py @@ -0,0 +1,185 @@ +# coding:utf-8 + +import random + +import matplotlib.pyplot as plt +import numpy as np +from scipy.stats import multivariate_normal + +from mla.base import BaseEstimator +from mla.kmeans import KMeans + + +class GaussianMixture(BaseEstimator): + """Gaussian Mixture Model: clusters with Gaussian prior. + + Finds clusters by repeatedly performing Expectation–Maximization (EM) algorithm + on the dataset. GMM assumes the datasets is distributed in multivariate Gaussian, + and tries to find the underlying structure of the Gaussian, i.e. mean and covariance. + E-step computes the "responsibility" of the data to each cluster, given the mean + and covariance; M-step computes the mean, covariance and weights (prior of each + cluster), given the responsibilities. It iterates until the total likelihood + changes less than the tolerance. + + + Parameters + ---------- + + K : int + The number of clusters into which the dataset is partitioned. + max_iters: int + The maximum iterations of assigning points to the perform EM. + Short-circuited by the assignments converging on their own. + init: str, default 'random' + The name of the method used to initialize the first clustering. + + 'random' - Randomly select values from the dataset as the K centroids. + 'kmeans' - Initialize the centroids, covariances, weights with KMeams's clusters. + tolerance: float, default 1e-3 + The tolerance of difference of the two latest likelihood for convergence. + """ + + y_required = False + + def __init__(self, K=4, init="random", max_iters=500, tolerance=1e-3): + self.K = K + self.max_iters = max_iters + self.init = init + self.assignments = None + self.likelihood = [] + self.tolerance = tolerance + + def fit(self, X, y=None): + """Perform Expectation–Maximization (EM) until converged.""" + self._setup_input(X, y) + self._initialize() + for _ in range(self.max_iters): + self._E_step() + self._M_step() + if self._is_converged(): + break + + def _initialize(self): + """Set the initial weights, means and covs (with full covariance matrix). + + weights: the prior of the clusters (what percentage of data does a cluster have) + means: the mean points of the clusters + covs: the covariance matrix of the clusters + """ + self.weights = np.ones(self.K) + if self.init == "random": + self.means = [ + self.X[x] for x in random.sample(range(self.n_samples), self.K) + ] + self.covs = [np.cov(self.X.T) for _ in range(self.K)] + + elif self.init == "kmeans": + kmeans = KMeans(K=self.K, max_iters=self.max_iters // 3, init="++") + kmeans.fit(self.X) + self.assignments = kmeans.predict() + self.means = kmeans.centroids + self.covs = [] + for i in np.unique(self.assignments): + self.weights[int(i)] = (self.assignments == i).sum() + self.covs.append(np.cov(self.X[self.assignments == i].T)) + else: + raise ValueError("Unknown type of init parameter") + self.weights /= self.weights.sum() + + def _E_step(self): + """Expectation(E-step) for Gaussian Mixture.""" + likelihoods = self._get_likelihood(self.X) + self.likelihood.append(likelihoods.sum()) + weighted_likelihoods = self._get_weighted_likelihood(likelihoods) + self.assignments = weighted_likelihoods.argmax(axis=1) + weighted_likelihoods /= weighted_likelihoods.sum(axis=1)[:, np.newaxis] + self.responsibilities = weighted_likelihoods + + def _M_step(self): + """Maximization (M-step) for Gaussian Mixture.""" + weights = self.responsibilities.sum(axis=0) + for assignment in range(self.K): + resp = self.responsibilities[:, assignment][:, np.newaxis] + self.means[assignment] = (resp * self.X).sum(axis=0) / resp.sum() + self.covs[assignment] = (self.X - self.means[assignment]).T.dot( + (self.X - self.means[assignment]) * resp + ) / weights[assignment] + self.weights = weights / weights.sum() + + def _is_converged(self): + """Check if the difference of the latest two likelihood is less than the tolerance.""" + if (len(self.likelihood) > 1) and ( + self.likelihood[-1] - self.likelihood[-2] <= self.tolerance + ): + return True + return False + + def _predict(self, X): + """Get the assignments for X with GMM clusters.""" + if not X.shape: + return self.assignments + likelihoods = self._get_likelihood(X) + weighted_likelihoods = self._get_weighted_likelihood(likelihoods) + assignments = weighted_likelihoods.argmax(axis=1) + return assignments + + def _get_likelihood(self, data): + n_data = data.shape[0] + likelihoods = np.zeros([n_data, self.K]) + for c in range(self.K): + likelihoods[:, c] = multivariate_normal.pdf( + data, self.means[c], self.covs[c] + ) + return likelihoods + + def _get_weighted_likelihood(self, likelihood): + return self.weights * likelihood + + def plot(self, data=None, ax=None, holdon=False): + """Plot contour for 2D data.""" + if not (len(self.X.shape) == 2 and self.X.shape[1] == 2): + raise AttributeError("Only support for visualizing 2D data.") + + if ax is None: + _, ax = plt.subplots() + + if data is None: + data = self.X + assignments = self.assignments + else: + assignments = self.predict(data) + + COLOR = "bgrcmyk" + cmap = lambda assignment: COLOR[int(assignment) % len(COLOR)] + + # generate grid + delta = 0.025 + margin = 0.2 + xmax, ymax = self.X.max(axis=0) + margin + xmin, ymin = self.X.min(axis=0) - margin + axis_X, axis_Y = np.meshgrid( + np.arange(xmin, xmax, delta), np.arange(ymin, ymax, delta) + ) + + def grid_gaussian_pdf(mean, cov): + grid_array = np.array(list(zip(axis_X.flatten(), axis_Y.flatten()))) + return multivariate_normal.pdf(grid_array, mean, cov).reshape(axis_X.shape) + + # plot scatters + if assignments is None: + c = None + else: + c = [cmap(assignment) for assignment in assignments] + ax.scatter(data[:, 0], data[:, 1], c=c) + + # plot contours + for assignment in range(self.K): + ax.contour( + axis_X, + axis_Y, + grid_gaussian_pdf(self.means[assignment], self.covs[assignment]), + colors=cmap(assignment), + ) + + if not holdon: + plt.show() diff --git a/mla/kmeans.py b/mla/kmeans.py new file mode 100644 index 0000000..fb3bc51 --- /dev/null +++ b/mla/kmeans.py @@ -0,0 +1,158 @@ +# coding:utf-8 + +import random + +import matplotlib.pyplot as plt +import numpy as np +import seaborn as sns + +from mla.base import BaseEstimator +from mla.metrics.distance import euclidean_distance + +random.seed(1111) + + +class KMeans(BaseEstimator): + """Partition a dataset into K clusters. + + Finds clusters by repeatedly assigning each data point to the cluster with + the nearest centroid and iterating until the assignments converge (meaning + they don't change during an iteration) or the maximum number of iterations + is reached. + + Parameters + ---------- + + K : int + The number of clusters into which the dataset is partitioned. + max_iters: int + The maximum iterations of assigning points to the nearest cluster. + Short-circuited by the assignments converging on their own. + init: str, default 'random' + The name of the method used to initialize the first clustering. + + 'random' - Randomly select values from the dataset as the K centroids. + '++' - Select a random first centroid from the dataset, then select + K - 1 more centroids by choosing values from the dataset with a + probability distribution proportional to the squared distance + from each point's closest existing cluster. Attempts to create + larger distances between initial clusters to improve convergence + rates and avoid degenerate cases. + """ + + y_required = False + + def __init__(self, K=5, max_iters=100, init="random"): + self.K = K + self.max_iters = max_iters + self.clusters = [[] for _ in range(self.K)] + self.centroids = [] + self.init = init + + def _initialize_centroids(self, init): + """Set the initial centroids.""" + + if init == "random": + self.centroids = [ + self.X[x] for x in random.sample(range(self.n_samples), self.K) + ] + elif init == "++": + self.centroids = [random.choice(self.X)] + while len(self.centroids) < self.K: + self.centroids.append(self._choose_next_center()) + else: + raise ValueError("Unknown type of init parameter") + + def _predict(self, X=None): + """Perform clustering on the dataset.""" + self._initialize_centroids(self.init) + centroids = self.centroids + + # Optimize clusters + for _ in range(self.max_iters): + self._assign(centroids) + centroids_old = centroids + centroids = [self._get_centroid(cluster) for cluster in self.clusters] + + if self._is_converged(centroids_old, centroids): + break + + self.centroids = centroids + + return self._get_predictions() + + def _get_predictions(self): + predictions = np.empty(self.n_samples) + + for i, cluster in enumerate(self.clusters): + for index in cluster: + predictions[index] = i + return predictions + + def _assign(self, centroids): + for row in range(self.n_samples): + for i, cluster in enumerate(self.clusters): + if row in cluster: + self.clusters[i].remove(row) + break + + closest = self._closest(row, centroids) + self.clusters[closest].append(row) + + def _closest(self, fpoint, centroids): + """Find the closest centroid for a point.""" + closest_index = None + closest_distance = None + for i, point in enumerate(centroids): + dist = euclidean_distance(self.X[fpoint], point) + if closest_index is None or dist < closest_distance: + closest_index = i + closest_distance = dist + return closest_index + + def _get_centroid(self, cluster): + """Get values by indices and take the mean.""" + return [np.mean(np.take(self.X[:, i], cluster)) for i in range(self.n_features)] + + def _dist_from_centers(self): + """Calculate distance from centers.""" + return np.array( + [min([euclidean_distance(x, c) for c in self.centroids]) for x in self.X] + ) + + def _choose_next_center(self): + distances = self._dist_from_centers() + squared_distances = distances**2 + probs = squared_distances / squared_distances.sum() + ind = np.random.choice(self.X.shape[0], 1, p=probs)[0] + return self.X[ind] + + def _is_converged(self, centroids_old, centroids): + """Check if the distance between old and new centroids is zero.""" + distance = 0 + for i in range(self.K): + distance += euclidean_distance(centroids_old[i], centroids[i]) + return distance == 0 + + def plot(self, ax=None, holdon=False): + sns.set(style="white") + palette = sns.color_palette("hls", self.K + 1) + data = self.X + + if ax is None: + _, ax = plt.subplots() + + for i, index in enumerate(self.clusters): + point = np.array(data[index]).T + ax.scatter( + *point, + c=[ + palette[i], + ], + ) + + for point in self.centroids: + ax.scatter(*point, marker="x", linewidths=10) + + if not holdon: + plt.show() diff --git a/mla/knn.py b/mla/knn.py new file mode 100644 index 0000000..f24c1d7 --- /dev/null +++ b/mla/knn.py @@ -0,0 +1,74 @@ +# coding:utf-8 + +from collections import Counter + +import numpy as np +from scipy.spatial.distance import euclidean + +from mla.base import BaseEstimator + + +class KNNBase(BaseEstimator): + def __init__(self, k=5, distance_func=euclidean): + """Base class for Nearest neighbors classifier and regressor. + + Parameters + ---------- + k : int, default 5 + The number of neighbors to take into account. If 0, all the + training examples are used. + distance_func : function, default euclidean distance + A distance function taking two arguments. Any function from + scipy.spatial.distance will do. + """ + + self.k = None if k == 0 else k # l[:None] returns the whole list + self.distance_func = distance_func + + def aggregate(self, neighbors_targets): + raise NotImplementedError() + + def _predict(self, X=None): + predictions = [self._predict_x(x) for x in X] + + return np.array(predictions) + + def _predict_x(self, x): + """Predict the label of a single instance x.""" + + # compute distances between x and all examples in the training set. + distances = (self.distance_func(x, example) for example in self.X) + + # Sort all examples by their distance to x and keep their target value. + neighbors = sorted( + ((dist, target) for (dist, target) in zip(distances, self.y)), + key=lambda x: x[0], + ) + + # Get targets of the k-nn and aggregate them (most common one or + # average). + neighbors_targets = [target for (_, target) in neighbors[: self.k]] + + return self.aggregate(neighbors_targets) + + +class KNNClassifier(KNNBase): + """Nearest neighbors classifier. + + Note: if there is a tie for the most common label among the neighbors, then + the predicted label is arbitrary.""" + + def aggregate(self, neighbors_targets): + """Return the most common target label.""" + + most_common_label = Counter(neighbors_targets).most_common(1)[0][0] + return most_common_label + + +class KNNRegressor(KNNBase): + """Nearest neighbors regressor.""" + + def aggregate(self, neighbors_targets): + """Return the mean of all targets.""" + + return np.mean(neighbors_targets) diff --git a/mla/linear_models.py b/mla/linear_models.py new file mode 100644 index 0000000..a7d351d --- /dev/null +++ b/mla/linear_models.py @@ -0,0 +1,138 @@ +# coding:utf-8 + +import logging + +import autograd.numpy as np +from autograd import grad + +from mla.base import BaseEstimator +from mla.metrics.metrics import mean_squared_error, binary_crossentropy + +np.random.seed(1000) + + +class BasicRegression(BaseEstimator): + def __init__( + self, lr=0.001, penalty="None", C=0.01, tolerance=0.0001, max_iters=1000 + ): + """Basic class for implementing continuous regression estimators which + are trained with gradient descent optimization on their particular loss + function. + + Parameters + ---------- + lr : float, default 0.001 + Learning rate. + penalty : str, {'l1', 'l2', None'}, default None + Regularization function name. + C : float, default 0.01 + The regularization coefficient. + tolerance : float, default 0.0001 + If the gradient descent updates are smaller than `tolerance`, then + stop optimization process. + max_iters : int, default 10000 + The maximum number of iterations. + """ + self.C = C + self.penalty = penalty + self.tolerance = tolerance + self.lr = lr + self.max_iters = max_iters + self.errors = [] + self.theta = [] + self.n_samples, self.n_features = None, None + self.cost_func = None + + def _loss(self, w): + raise NotImplementedError() + + def init_cost(self): + raise NotImplementedError() + + def _add_penalty(self, loss, w): + """Apply regularization to the loss.""" + if self.penalty == "l1": + loss += self.C * np.abs(w[1:]).sum() + elif self.penalty == "l2": + loss += (0.5 * self.C) * (w[1:] ** 2).sum() + return loss + + def _cost(self, X, y, theta): + prediction = X.dot(theta) + error = self.cost_func(y, prediction) + return error + + def fit(self, X, y=None): + self._setup_input(X, y) + self.init_cost() + self.n_samples, self.n_features = X.shape + + # Initialize weights + bias term + self.theta = np.random.normal(size=(self.n_features + 1), scale=0.5) + + # Add an intercept column + self.X = self._add_intercept(self.X) + + self._train() + + @staticmethod + def _add_intercept(X): + b = np.ones([X.shape[0], 1]) + return np.concatenate([b, X], axis=1) + + def _train(self): + self.theta, self.errors = self._gradient_descent() + logging.info(" Theta: %s" % self.theta.flatten()) + + def _predict(self, X=None): + X = self._add_intercept(X) + return X.dot(self.theta) + + def _gradient_descent(self): + theta = self.theta + errors = [self._cost(self.X, self.y, theta)] + # Get derivative of the loss function + cost_d = grad(self._loss) + for i in range(1, self.max_iters + 1): + # Calculate gradient and update theta + delta = cost_d(theta) + theta -= self.lr * delta + + errors.append(self._cost(self.X, self.y, theta)) + logging.info("Iteration %s, error %s" % (i, errors[i])) + + error_diff = np.linalg.norm(errors[i - 1] - errors[i]) + if error_diff < self.tolerance: + logging.info("Convergence has reached.") + break + return theta, errors + + +class LinearRegression(BasicRegression): + """Linear regression with gradient descent optimizer.""" + + def _loss(self, w): + loss = self.cost_func(self.y, np.dot(self.X, w)) + return self._add_penalty(loss, w) + + def init_cost(self): + self.cost_func = mean_squared_error + + +class LogisticRegression(BasicRegression): + """Binary logistic regression with gradient descent optimizer.""" + + def init_cost(self): + self.cost_func = binary_crossentropy + + def _loss(self, w): + loss = self.cost_func(self.y, self.sigmoid(np.dot(self.X, w))) + return self._add_penalty(loss, w) + + @staticmethod + def sigmoid(x): + return 0.5 * (np.tanh(0.5 * x) + 1) + + def _predict(self, X=None): + X = self._add_intercept(X) + return self.sigmoid(X.dot(self.theta)) diff --git a/mla/metrics/__init__.py b/mla/metrics/__init__.py new file mode 100644 index 0000000..db3e0b3 --- /dev/null +++ b/mla/metrics/__init__.py @@ -0,0 +1,2 @@ +# coding:utf-8 +from .metrics import * diff --git a/mla/metrics/base.py b/mla/metrics/base.py new file mode 100644 index 0000000..065e5bc --- /dev/null +++ b/mla/metrics/base.py @@ -0,0 +1,25 @@ +# coding:utf-8 +import numpy as np + + +def check_data(a, b): + if not isinstance(a, np.ndarray): + a = np.array(a) + + if not isinstance(b, np.ndarray): + b = np.array(b) + + if type(a) != type(b): + raise ValueError("Type mismatch: %s and %s" % (type(a), type(b))) + + if a.size != b.size: + raise ValueError("Arrays must be equal in length.") + return a, b + + +def validate_input(function): + def wrapper(a, b): + a, b = check_data(a, b) + return function(a, b) + + return wrapper diff --git a/mla/metrics/distance.py b/mla/metrics/distance.py new file mode 100644 index 0000000..919d465 --- /dev/null +++ b/mla/metrics/distance.py @@ -0,0 +1,17 @@ +# coding:utf-8 +import math + +import numpy as np + + +def euclidean_distance(a, b): + if isinstance(a, list) and isinstance(b, list): + a = np.array(a) + b = np.array(b) + + return math.sqrt(sum((a - b) ** 2)) + + +def l2_distance(X): + sum_X = np.sum(X * X, axis=1) + return (-2 * np.dot(X, X.T) + sum_X).T + sum_X diff --git a/mla/metrics/metrics.py b/mla/metrics/metrics.py new file mode 100644 index 0000000..3cffcee --- /dev/null +++ b/mla/metrics/metrics.py @@ -0,0 +1,90 @@ +# coding:utf-8 +import autograd.numpy as np + +EPS = 1e-15 + + +def unhot(function): + """Convert one-hot representation into one column.""" + + def wrapper(actual, predicted): + if len(actual.shape) > 1 and actual.shape[1] > 1: + actual = actual.argmax(axis=1) + if len(predicted.shape) > 1 and predicted.shape[1] > 1: + predicted = predicted.argmax(axis=1) + return function(actual, predicted) + + return wrapper + + +def absolute_error(actual, predicted): + return np.abs(actual - predicted) + + +@unhot +def classification_error(actual, predicted): + return (actual != predicted).sum() / float(actual.shape[0]) + + +@unhot +def accuracy(actual, predicted): + return 1.0 - classification_error(actual, predicted) + + +def mean_absolute_error(actual, predicted): + return np.mean(absolute_error(actual, predicted)) + + +def squared_error(actual, predicted): + return (actual - predicted) ** 2 + + +def squared_log_error(actual, predicted): + return (np.log(np.array(actual) + 1) - np.log(np.array(predicted) + 1)) ** 2 + + +def mean_squared_log_error(actual, predicted): + return np.mean(squared_log_error(actual, predicted)) + + +def mean_squared_error(actual, predicted): + return np.mean(squared_error(actual, predicted)) + + +def root_mean_squared_error(actual, predicted): + return np.sqrt(mean_squared_error(actual, predicted)) + + +def root_mean_squared_log_error(actual, predicted): + return np.sqrt(mean_squared_log_error(actual, predicted)) + + +def logloss(actual, predicted): + predicted = np.clip(predicted, EPS, 1 - EPS) + loss = -np.sum(actual * np.log(predicted)) + return loss / float(actual.shape[0]) + + +def hinge(actual, predicted): + return np.mean(np.max(1.0 - actual * predicted, 0.0)) + + +def binary_crossentropy(actual, predicted): + predicted = np.clip(predicted, EPS, 1 - EPS) + return np.mean( + -np.sum(actual * np.log(predicted) + (1 - actual) * np.log(1 - predicted)) + ) + + +# aliases +mse = mean_squared_error +rmse = root_mean_squared_error +mae = mean_absolute_error + + +def get_metric(name): + """Return metric function by name""" + try: + return globals()[name] + except Exception: + raise ValueError("Invalid metric function.") diff --git a/mla/metrics/tests/__init__.py b/mla/metrics/tests/__init__.py new file mode 100644 index 0000000..f512dea --- /dev/null +++ b/mla/metrics/tests/__init__.py @@ -0,0 +1 @@ +# coding:utf-8 diff --git a/mla/metrics/tests/test_metrics.py b/mla/metrics/tests/test_metrics.py new file mode 100644 index 0000000..307dca7 --- /dev/null +++ b/mla/metrics/tests/test_metrics.py @@ -0,0 +1,88 @@ +from __future__ import division + +import numpy as np +import pytest +from numpy.testing import assert_almost_equal + +from mla.metrics.base import check_data, validate_input +from mla.metrics.metrics import get_metric + + +def test_data_validation(): + with pytest.raises(ValueError): + check_data([], 1) + + with pytest.raises(ValueError): + check_data([1, 2, 3], [3, 2]) + + a, b = check_data([1, 2, 3], [3, 2, 1]) + + assert np.all(a == np.array([1, 2, 3])) + assert np.all(b == np.array([3, 2, 1])) + + +def metric(name): + return validate_input(get_metric(name)) + + +def test_classification_error(): + f = metric("classification_error") + assert f([1, 2, 3, 4], [1, 2, 3, 4]) == 0 + assert f([1, 2, 3, 4], [1, 2, 3, 5]) == 0.25 + assert f([1, 1, 1, 0, 0, 0], [1, 1, 1, 1, 0, 0]) == (1.0 / 6) + + +def test_absolute_error(): + f = metric("absolute_error") + assert f([3], [5]) == [2] + assert f([-1], [-4]) == [3] + + +def test_mean_absolute_error(): + f = metric("mean_absolute_error") + assert f([1, 2, 3], [1, 2, 3]) == 0 + assert f([1, 2, 3], [3, 2, 1]) == 4 / 3 + + +def test_squared_error(): + f = metric("squared_error") + assert f([1], [1]) == [0] + assert f([3], [1]) == [4] + + +def test_squared_log_error(): + f = metric("squared_log_error") + assert f([1], [1]) == [0] + assert f([3], [1]) == [np.log(2) ** 2] + assert f([np.exp(2) - 1], [np.exp(1) - 1]) == [1.0] + + +def test_mean_squared_log_error(): + f = metric("mean_squared_log_error") + assert f([1, 2, 3], [1, 2, 3]) == 0 + assert f([1, 2, 3, np.exp(1) - 1], [1, 2, 3, np.exp(2) - 1]) == 0.25 + + +def test_root_mean_squared_log_error(): + f = metric("root_mean_squared_log_error") + assert f([1, 2, 3], [1, 2, 3]) == 0 + assert f([1, 2, 3, np.exp(1) - 1], [1, 2, 3, np.exp(2) - 1]) == 0.5 + + +def test_mean_squared_error(): + f = metric("mean_squared_error") + assert f([1, 2, 3], [1, 2, 3]) == 0 + assert f(range(1, 5), [1, 2, 3, 6]) == 1 + + +def test_root_mean_squared_error(): + f = metric("root_mean_squared_error") + assert f([1, 2, 3], [1, 2, 3]) == 0 + assert f(range(1, 5), [1, 2, 3, 5]) == 0.5 + + +def test_multiclass_logloss(): + f = metric("logloss") + assert_almost_equal(f([1], [1]), 0) + assert_almost_equal(f([1, 1], [1, 1]), 0) + assert_almost_equal(f([1], [0.5]), -np.log(0.5)) diff --git a/mla/naive_bayes.py b/mla/naive_bayes.py new file mode 100644 index 0000000..16ba89e --- /dev/null +++ b/mla/naive_bayes.py @@ -0,0 +1,61 @@ +# coding:utf-8 + +import numpy as np + +from mla.base import BaseEstimator +from mla.neuralnet.activations import softmax + + +class NaiveBayesClassifier(BaseEstimator): + """Gaussian Naive Bayes.""" + + # Binary problem. + n_classes = 2 + + def fit(self, X, y=None): + self._setup_input(X, y) + # Check target labels + assert list(np.unique(y)) == [0, 1] + + # Mean and variance for each class and feature combination + self._mean = np.zeros((self.n_classes, self.n_features), dtype=np.float64) + self._var = np.zeros((self.n_classes, self.n_features), dtype=np.float64) + + self._priors = np.zeros(self.n_classes, dtype=np.float64) + + for c in range(self.n_classes): + # Filter features by class + X_c = X[y == c] + + # Calculate mean, variance, prior for each class + self._mean[c, :] = X_c.mean(axis=0) + self._var[c, :] = X_c.var(axis=0) + self._priors[c] = X_c.shape[0] / float(X.shape[0]) + + def _predict(self, X=None): + # Apply _predict_proba for each row + predictions = np.apply_along_axis(self._predict_row, 1, X) + + # Normalize probabilities so that each row will sum up to 1.0 + return softmax(predictions) + + def _predict_row(self, x): + """Predict log likelihood for given row.""" + output = [] + for y in range(self.n_classes): + prior = np.log(self._priors[y]) + posterior = np.log(self._pdf(y, x)).sum() + prediction = prior + posterior + + output.append(prediction) + return output + + def _pdf(self, n_class, x): + """Calculate Gaussian PDF for each feature.""" + + mean = self._mean[n_class] + var = self._var[n_class] + + numerator = np.exp(-((x - mean) ** 2) / (2 * var)) + denominator = np.sqrt(2 * np.pi * var) + return numerator / denominator diff --git a/mla/neuralnet/__init__.py b/mla/neuralnet/__init__.py new file mode 100644 index 0000000..0291fed --- /dev/null +++ b/mla/neuralnet/__init__.py @@ -0,0 +1 @@ +from .nnet import NeuralNet diff --git a/mla/neuralnet/activations.py b/mla/neuralnet/activations.py new file mode 100644 index 0000000..1ddd763 --- /dev/null +++ b/mla/neuralnet/activations.py @@ -0,0 +1,64 @@ +import autograd.numpy as np + +""" +References: +https://en.wikipedia.org/wiki/Activation_function +""" + + +def sigmoid(z): + return 1.0 / (1.0 + np.exp(-z)) + + +def softmax(z): + # Avoid numerical overflow by removing max + e = np.exp(z - np.amax(z, axis=1, keepdims=True)) + return e / np.sum(e, axis=1, keepdims=True) + + +def linear(z): + return z + + +def softplus(z): + """Smooth relu.""" + # Avoid numerical overflow, see: + # https://docs.scipy.org/doc/numpy/reference/generated/numpy.logaddexp.html + return np.logaddexp(0.0, z) + + +def softsign(z): + return z / (1 + np.abs(z)) + + +def tanh(z): + return np.tanh(z) + + +def relu(z): + return np.maximum(0, z) + + +def leakyrelu(z, a=0.01): + return np.maximum(z * a, z) + + +def gelu(z): + """ + Gaussian Error Linear Unit (GELU) + """ + # mainly used in transformers smoother version of relu + + return 0.5 * z * ( + 1.0 + np.tanh( + np.sqrt(2.0 / np.pi) * (z + 0.044715 * np.power(z, 3)) + ) + ) + + +def get_activation(name): + """Return activation function by name""" + try: + return globals()[name] + except Exception: + raise ValueError("Invalid activation function.") diff --git a/mla/neuralnet/constraints.py b/mla/neuralnet/constraints.py new file mode 100644 index 0000000..d33e410 --- /dev/null +++ b/mla/neuralnet/constraints.py @@ -0,0 +1,40 @@ +# coding:utf-8 +import numpy as np + +EPSILON = 10e-8 + + +class Constraint(object): + def clip(self, p): + return p + + +class MaxNorm(object): + def __init__(self, m=2, axis=0): + self.axis = axis + self.m = m + + def clip(self, p): + norms = np.sqrt(np.sum(p**2, axis=self.axis)) + desired = np.clip(norms, 0, self.m) + p = p * (desired / (EPSILON + norms)) + return p + + +class NonNeg(object): + def clip(self, p): + p[p < 0.0] = 0.0 + return p + + +class SmallNorm(object): + def clip(self, p): + return np.clip(p, -5, 5) + + +class UnitNorm(Constraint): + def __init__(self, axis=0): + self.axis = axis + + def clip(self, p): + return p / (EPSILON + np.sqrt(np.sum(p**2, axis=self.axis))) diff --git a/mla/neuralnet/initializations.py b/mla/neuralnet/initializations.py new file mode 100644 index 0000000..f67fe9f --- /dev/null +++ b/mla/neuralnet/initializations.py @@ -0,0 +1,75 @@ +import numpy as np + +""" +References: +http://jmlr.org/proceedings/papers/v9/glorot10a/glorot10a.pdf + +""" + + +def normal(shape, scale=0.5): + return np.random.normal(size=shape, scale=scale) + + +def uniform(shape, scale=0.5): + return np.random.uniform(size=shape, low=-scale, high=scale) + + +def zero(shape, **kwargs): + return np.zeros(shape) + + +def one(shape, **kwargs): + return np.ones(shape) + + +def orthogonal(shape, scale=0.5): + flat_shape = (shape[0], np.prod(shape[1:])) + array = np.random.normal(size=flat_shape) + u, _, v = np.linalg.svd(array, full_matrices=False) + array = u if u.shape == flat_shape else v + return np.reshape(array * scale, shape) + + +def _glorot_fan(shape): + assert len(shape) >= 2 + + if len(shape) == 4: + receptive_field_size = np.prod(shape[2:]) + fan_in = shape[1] * receptive_field_size + fan_out = shape[0] * receptive_field_size + else: + fan_in, fan_out = shape[:2] + return float(fan_in), float(fan_out) + + +def glorot_normal(shape, **kwargs): + fan_in, fan_out = _glorot_fan(shape) + s = np.sqrt(2.0 / (fan_in + fan_out)) + return normal(shape, s) + + +def glorot_uniform(shape, **kwargs): + fan_in, fan_out = _glorot_fan(shape) + s = np.sqrt(6.0 / (fan_in + fan_out)) + return uniform(shape, s) + + +def he_normal(shape, **kwargs): + fan_in, fan_out = _glorot_fan(shape) + s = np.sqrt(2.0 / fan_in) + return normal(shape, s) + + +def he_uniform(shape, **kwargs): + fan_in, fan_out = _glorot_fan(shape) + s = np.sqrt(6.0 / fan_in) + return uniform(shape, s) + + +def get_initializer(name): + """Returns initialization function by the name.""" + try: + return globals()[name] + except Exception: + raise ValueError("Invalid initialization function.") diff --git a/mla/neuralnet/layers/__init__.py b/mla/neuralnet/layers/__init__.py new file mode 100644 index 0000000..9b72704 --- /dev/null +++ b/mla/neuralnet/layers/__init__.py @@ -0,0 +1,4 @@ +# coding:utf-8 +from .basic import * +from .convnet import * +from .normalization import * diff --git a/mla/neuralnet/layers/basic.py b/mla/neuralnet/layers/basic.py new file mode 100644 index 0000000..119855e --- /dev/null +++ b/mla/neuralnet/layers/basic.py @@ -0,0 +1,183 @@ +# coding:utf-8 +import autograd.numpy as np +from autograd import elementwise_grad + +from mla.neuralnet.activations import get_activation +from mla.neuralnet.parameters import Parameters + +np.random.seed(9999) + + +class Layer(object): + def setup(self, X_shape): + """Allocates initial weights.""" + pass + + def forward_pass(self, x): + raise NotImplementedError() + + def backward_pass(self, delta): + raise NotImplementedError() + + def shape(self, x_shape): + """Returns shape of the current layer.""" + raise NotImplementedError() + + +class ParamMixin(object): + @property + def parameters(self): + return self._params + + +class PhaseMixin(object): + _train = False + + @property + def is_training(self): + return self._train + + @is_training.setter + def is_training(self, is_train=True): + self._train = is_train + + @property + def is_testing(self): + return not self._train + + @is_testing.setter + def is_testing(self, is_test=True): + self._train = not is_test + + +class Dense(Layer, ParamMixin): + def __init__(self, output_dim, parameters=None): + """A fully connected layer. + + Parameters + ---------- + output_dim : int + """ + self._params = parameters + self.output_dim = output_dim + self.last_input = None + + if parameters is None: + self._params = Parameters() + + def setup(self, x_shape): + self._params.setup_weights((x_shape[1], self.output_dim)) + + def forward_pass(self, X): + self.last_input = X + return self.weight(X) + + def weight(self, X): + W = np.dot(X, self._params["W"]) + return W + self._params["b"] + + def backward_pass(self, delta): + dW = np.dot(self.last_input.T, delta) + db = np.sum(delta, axis=0) + + # Update gradient values + self._params.update_grad("W", dW) + self._params.update_grad("b", db) + return np.dot(delta, self._params["W"].T) + + def shape(self, x_shape): + return x_shape[0], self.output_dim + + +class Activation(Layer): + def __init__(self, name): + self.last_input = None + self.activation = get_activation(name) + # Derivative of activation function + self.activation_d = elementwise_grad(self.activation) + + def forward_pass(self, X): + self.last_input = X + return self.activation(X) + + def backward_pass(self, delta): + return self.activation_d(self.last_input) * delta + + def shape(self, x_shape): + return x_shape + + +class Dropout(Layer, PhaseMixin): + """Randomly set a fraction of `p` inputs to 0 at each training update.""" + + def __init__(self, p=0.1): + self.p = p + self._mask = None + + def forward_pass(self, X): + assert self.p > 0 + if self.is_training: + self._mask = np.random.uniform(size=X.shape) > self.p + y = X * self._mask + else: + y = X * (1.0 - self.p) + + return y + + def backward_pass(self, delta): + return delta * self._mask + + def shape(self, x_shape): + return x_shape + + +class TimeStepSlicer(Layer): + """Take a specific time step from 3D tensor.""" + + def __init__(self, step=-1): + self.step = step + + def forward_pass(self, x): + return x[:, self.step, :] + + def backward_pass(self, delta): + return np.repeat(delta[:, np.newaxis, :], 2, 1) + + def shape(self, x_shape): + return x_shape[0], x_shape[2] + + +class TimeDistributedDense(Layer): + """Apply regular Dense layer to every timestep.""" + + def __init__(self, output_dim): + self.output_dim = output_dim + self.n_timesteps = None + self.dense = None + self.input_dim = None + + def setup(self, X_shape): + self.dense = Dense(self.output_dim) + self.dense.setup((X_shape[0], X_shape[2])) + self.input_dim = X_shape[2] + + def forward_pass(self, X): + n_timesteps = X.shape[1] + X = X.reshape(-1, X.shape[-1]) + y = self.dense.forward_pass(X) + y = y.reshape((-1, n_timesteps, self.output_dim)) + return y + + def backward_pass(self, delta): + n_timesteps = delta.shape[1] + X = delta.reshape(-1, delta.shape[-1]) + y = self.dense.backward_pass(X) + y = y.reshape((-1, n_timesteps, self.input_dim)) + return y + + @property + def parameters(self): + return self.dense._params + + def shape(self, x_shape): + return x_shape[0], x_shape[1], self.output_dim diff --git a/mla/neuralnet/layers/convnet.py b/mla/neuralnet/layers/convnet.py new file mode 100644 index 0000000..40ecef1 --- /dev/null +++ b/mla/neuralnet/layers/convnet.py @@ -0,0 +1,231 @@ +# coding:utf-8 +import autograd.numpy as np + +from mla.neuralnet.layers import Layer, ParamMixin +from mla.neuralnet.parameters import Parameters + + +class Convolution(Layer, ParamMixin): + def __init__( + self, + n_filters=8, + filter_shape=(3, 3), + padding=(0, 0), + stride=(1, 1), + parameters=None, + ): + """A 2D convolutional layer. + Input shape: (n_images, n_channels, height, width) + + Parameters + ---------- + n_filters : int, default 8 + The number of filters (kernels). + filter_shape : tuple(int, int), default (3, 3) + The shape of the filters. (height, width) + parameters : Parameters instance, default None + stride : tuple(int, int), default (1, 1) + The step of the convolution. (height, width). + padding : tuple(int, int), default (0, 0) + The number of pixel to add to each side of the input. (height, weight) + + """ + self.padding = padding + self._params = parameters + self.stride = stride + self.filter_shape = filter_shape + self.n_filters = n_filters + if self._params is None: + self._params = Parameters() + + def setup(self, X_shape): + n_channels, self.height, self.width = X_shape[1:] + + W_shape = (self.n_filters, n_channels) + self.filter_shape + b_shape = self.n_filters + self._params.setup_weights(W_shape, b_shape) + + def forward_pass(self, X): + n_images, n_channels, height, width = self.shape(X.shape) + self.last_input = X + self.col = image_to_column(X, self.filter_shape, self.stride, self.padding) + self.col_W = self._params["W"].reshape(self.n_filters, -1).T + + out = np.dot(self.col, self.col_W) + self._params["b"] + out = out.reshape(n_images, height, width, -1).transpose(0, 3, 1, 2) + return out + + def backward_pass(self, delta): + delta = delta.transpose(0, 2, 3, 1).reshape(-1, self.n_filters) + + d_W = np.dot(self.col.T, delta).transpose(1, 0).reshape(self._params["W"].shape) + d_b = np.sum(delta, axis=0) + self._params.update_grad("b", d_b) + self._params.update_grad("W", d_W) + + d_c = np.dot(delta, self.col_W.T) + return column_to_image( + d_c, self.last_input.shape, self.filter_shape, self.stride, self.padding + ) + + def shape(self, x_shape): + height, width = convoltuion_shape( + self.height, self.width, self.filter_shape, self.stride, self.padding + ) + return x_shape[0], self.n_filters, height, width + + +class MaxPooling(Layer): + def __init__(self, pool_shape=(2, 2), stride=(1, 1), padding=(0, 0)): + """Max pooling layer. + Input shape: (n_images, n_channels, height, width) + + Parameters + ---------- + pool_shape : tuple(int, int), default (2, 2) + stride : tuple(int, int), default (1,1) + padding : tuple(int, int), default (0,0) + """ + self.pool_shape = pool_shape + self.stride = stride + self.padding = padding + + def forward_pass(self, X): + self.last_input = X + + out_height, out_width = pooling_shape(self.pool_shape, X.shape, self.stride) + n_images, n_channels, _, _ = X.shape + + col = image_to_column(X, self.pool_shape, self.stride, self.padding) + col = col.reshape(-1, self.pool_shape[0] * self.pool_shape[1]) + + arg_max = np.argmax(col, axis=1) + out = np.max(col, axis=1) + self.arg_max = arg_max + return out.reshape(n_images, out_height, out_width, n_channels).transpose( + 0, 3, 1, 2 + ) + + def backward_pass(self, delta): + delta = delta.transpose(0, 2, 3, 1) + + pool_size = self.pool_shape[0] * self.pool_shape[1] + y_max = np.zeros((delta.size, pool_size)) + y_max[np.arange(self.arg_max.size), self.arg_max.flatten()] = delta.flatten() + y_max = y_max.reshape(delta.shape + (pool_size,)) + + dcol = y_max.reshape(y_max.shape[0] * y_max.shape[1] * y_max.shape[2], -1) + return column_to_image( + dcol, self.last_input.shape, self.pool_shape, self.stride, self.padding + ) + + def shape(self, x_shape): + h, w = convoltuion_shape( + x_shape[2], x_shape[3], self.pool_shape, self.stride, self.padding + ) + return x_shape[0], x_shape[1], h, w + + +class Flatten(Layer): + """Flattens multidimensional input into 2D matrix.""" + + def forward_pass(self, X): + self.last_input_shape = X.shape + return X.reshape((X.shape[0], -1)) + + def backward_pass(self, delta): + return delta.reshape(self.last_input_shape) + + def shape(self, x_shape): + return x_shape[0], np.prod(x_shape[1:]) + + +def image_to_column(images, filter_shape, stride, padding): + """Rearrange image blocks into columns. + + Parameters + ---------- + + filter_shape : tuple(height, width) + images : np.array, shape (n_images, n_channels, height, width) + padding: tuple(height, width) + stride : tuple (height, width) + + """ + n_images, n_channels, height, width = images.shape + f_height, f_width = filter_shape + out_height, out_width = convoltuion_shape( + height, width, (f_height, f_width), stride, padding + ) + images = np.pad(images, ((0, 0), (0, 0), padding, padding), mode="constant") + + col = np.zeros((n_images, n_channels, f_height, f_width, out_height, out_width)) + for y in range(f_height): + y_bound = y + stride[0] * out_height + for x in range(f_width): + x_bound = x + stride[1] * out_width + col[:, :, y, x, :, :] = images[ + :, :, y : y_bound : stride[0], x : x_bound : stride[1] + ] + + col = col.transpose(0, 4, 5, 1, 2, 3).reshape(n_images * out_height * out_width, -1) + return col + + +def column_to_image(columns, images_shape, filter_shape, stride, padding): + """Rearrange columns into image blocks. + + Parameters + ---------- + columns + images_shape : tuple(n_images, n_channels, height, width) + filter_shape : tuple(height, _width) + stride : tuple(height, width) + padding : tuple(height, width) + """ + n_images, n_channels, height, width = images_shape + f_height, f_width = filter_shape + + out_height, out_width = convoltuion_shape( + height, width, (f_height, f_width), stride, padding + ) + columns = columns.reshape( + n_images, out_height, out_width, n_channels, f_height, f_width + ).transpose(0, 3, 4, 5, 1, 2) + + img_h = height + 2 * padding[0] + stride[0] - 1 + img_w = width + 2 * padding[1] + stride[1] - 1 + img = np.zeros((n_images, n_channels, img_h, img_w)) + for y in range(f_height): + y_bound = y + stride[0] * out_height + for x in range(f_width): + x_bound = x + stride[1] * out_width + img[:, :, y : y_bound : stride[0], x : x_bound : stride[1]] += columns[ + :, :, y, x, :, : + ] + + return img[:, :, padding[0] : height + padding[0], padding[1] : width + padding[1]] + + +def convoltuion_shape(img_height, img_width, filter_shape, stride, padding): + """Calculate output shape for convolution layer.""" + height = (img_height + 2 * padding[0] - filter_shape[0]) / float(stride[0]) + 1 + width = (img_width + 2 * padding[1] - filter_shape[1]) / float(stride[1]) + 1 + + assert height % 1 == 0 + assert width % 1 == 0 + + return int(height), int(width) + + +def pooling_shape(pool_shape, image_shape, stride): + """Calculate output shape for pooling layer.""" + n_images, n_channels, height, width = image_shape + + height = (height - pool_shape[0]) / float(stride[0]) + 1 + width = (width - pool_shape[1]) / float(stride[1]) + 1 + + assert height % 1 == 0 + assert width % 1 == 0 + + return int(height), int(width) diff --git a/mla/neuralnet/layers/normalization.py b/mla/neuralnet/layers/normalization.py new file mode 100644 index 0000000..4ed7705 --- /dev/null +++ b/mla/neuralnet/layers/normalization.py @@ -0,0 +1,158 @@ +# coding:utf-8 +import numpy as np + +from mla.neuralnet.layers import Layer, PhaseMixin, ParamMixin +from mla.neuralnet.parameters import Parameters + +""" +References: +https://kratzert.github.io/2016/02/12/understanding-the-gradient-flow-through-the-batch-normalization-layer.html +""" + + +class BatchNormalization(Layer, ParamMixin, PhaseMixin): + def __init__(self, momentum=0.9, eps=1e-5, parameters=None): + super().__init__() + self._params = parameters + if self._params is None: + self._params = Parameters() + self.momentum = momentum + self.eps = eps + self.ema_mean = None + self.ema_var = None + + def setup(self, x_shape): + self._params.setup_weights((1, x_shape[1])) + + def _forward_pass(self, X): + gamma = self._params["W"] + beta = self._params["b"] + + if self.is_testing: + mu = self.ema_mean + xmu = X - mu + var = self.ema_var + sqrtvar = np.sqrt(var + self.eps) + ivar = 1.0 / sqrtvar + xhat = xmu * ivar + gammax = gamma * xhat + return gammax + beta + + N, D = X.shape + + # step1: calculate mean + mu = 1.0 / N * np.sum(X, axis=0) + + # step2: subtract mean vector of every trainings example + xmu = X - mu + + # step3: following the lower branch - calculation denominator + sq = xmu**2 + + # step4: calculate variance + var = 1.0 / N * np.sum(sq, axis=0) + + # step5: add eps for numerical stability, then sqrt + sqrtvar = np.sqrt(var + self.eps) + + # step6: invert sqrtwar + ivar = 1.0 / sqrtvar + + # step7: execute normalization + xhat = xmu * ivar + + # step8: Nor the two transformation steps + gammax = gamma * xhat + + # step9 + out = gammax + beta + + # store running averages of mean and variance during training for use during testing + if self.ema_mean is None or self.ema_var is None: + self.ema_mean = mu + self.ema_var = var + else: + self.ema_mean = self.momentum * self.ema_mean + (1 - self.momentum) * mu + self.ema_var = self.momentum * self.ema_var + (1 - self.momentum) * var + # store intermediate + self.cache = (xhat, gamma, xmu, ivar, sqrtvar, var) + + return out + + def forward_pass(self, X): + if len(X.shape) == 2: + # input is a regular layer + return self._forward_pass(X) + elif len(X.shape) == 4: + # input is a convolution layer + N, C, H, W = X.shape + x_flat = X.transpose(0, 2, 3, 1).reshape(-1, C) + out_flat = self._forward_pass(x_flat) + return out_flat.reshape(N, H, W, C).transpose(0, 3, 1, 2) + else: + raise NotImplementedError( + "Unknown model with dimensions = {}".format(len(X.shape)) + ) + + def _backward_pass(self, delta): + # unfold the variables stored in cache + xhat, gamma, xmu, ivar, sqrtvar, var = self.cache + + # get the dimensions of the input/output + N, D = delta.shape + + # step9 + dbeta = np.sum(delta, axis=0) + dgammax = delta # not necessary, but more understandable + + # step8 + dgamma = np.sum(dgammax * xhat, axis=0) + dxhat = dgammax * gamma + + # step7 + divar = np.sum(dxhat * xmu, axis=0) + dxmu1 = dxhat * ivar + + # step6 + dsqrtvar = -1.0 / (sqrtvar**2) * divar + + # step5 + dvar = 0.5 * 1.0 / np.sqrt(var + self.eps) * dsqrtvar + + # step4 + dsq = 1.0 / N * np.ones((N, D)) * dvar + + # step3 + dxmu2 = 2 * xmu * dsq + + # step2 + dx1 = dxmu1 + dxmu2 + dmu = -1 * np.sum(dxmu1 + dxmu2, axis=0) + + # step1 + dx2 = 1.0 / N * np.ones((N, D)) * dmu + + # step0 + dx = dx1 + dx2 + + # Update gradient values + self._params.update_grad("W", dgamma) + self._params.update_grad("b", dbeta) + + return dx + + def backward_pass(self, X): + if len(X.shape) == 2: + # input is a regular layer + return self._backward_pass(X) + elif len(X.shape) == 4: + # input is a convolution layer + N, C, H, W = X.shape + x_flat = X.transpose(0, 2, 3, 1).reshape(-1, C) + out_flat = self._backward_pass(x_flat) + return out_flat.reshape(N, H, W, C).transpose(0, 3, 1, 2) + else: + raise NotImplementedError("Unknown model shape: {}".format(X.shape)) + + def shape(self, x_shape): + return x_shape diff --git a/mla/neuralnet/layers/recurrent/__init__.py b/mla/neuralnet/layers/recurrent/__init__.py new file mode 100644 index 0000000..390b575 --- /dev/null +++ b/mla/neuralnet/layers/recurrent/__init__.py @@ -0,0 +1,3 @@ +# coding:utf-8 +from .lstm import * +from .rnn import * diff --git a/mla/neuralnet/layers/recurrent/lstm.py b/mla/neuralnet/layers/recurrent/lstm.py new file mode 100644 index 0000000..9997f61 --- /dev/null +++ b/mla/neuralnet/layers/recurrent/lstm.py @@ -0,0 +1,195 @@ +# coding:utf-8 +import autograd.numpy as np +from autograd import elementwise_grad + +from mla.neuralnet.activations import sigmoid +from mla.neuralnet.initializations import get_initializer +from mla.neuralnet.layers import Layer, get_activation, ParamMixin +from mla.neuralnet.parameters import Parameters + +""" +References: +Understanding LSTM Networks http://colah.github.io/posts/2015-08-Understanding-LSTMs/ +A Critical Review of Recurrent Neural Networks for Sequence Learning http://arxiv.org/pdf/1506.00019v4.pdf +""" + + +class LSTM(Layer, ParamMixin): + def __init__( + self, + hidden_dim, + activation="tanh", + inner_init="orthogonal", + parameters=None, + return_sequences=True, + ): + self.return_sequences = return_sequences + self.hidden_dim = hidden_dim + self.inner_init = get_initializer(inner_init) + self.activation = get_activation(activation) + self.activation_d = elementwise_grad(self.activation) + self.sigmoid_d = elementwise_grad(sigmoid) + + if parameters is None: + self._params = Parameters() + else: + self._params = parameters + + self.last_input = None + self.states = None + self.outputs = None + self.gates = None + self.hprev = None + self.input_dim = None + self.W = None + self.U = None + + def setup(self, x_shape): + """ + Naming convention: + i : input gate + f : forget gate + c : cell + o : output gate + + Parameters + ---------- + x_shape : np.array(batch size, time steps, input shape) + """ + self.input_dim = x_shape[2] + # Input -> Hidden + W_params = ["W_i", "W_f", "W_o", "W_c"] + # Hidden -> Hidden + U_params = ["U_i", "U_f", "U_o", "U_c"] + # Bias terms + b_params = ["b_i", "b_f", "b_o", "b_c"] + + # Initialize params + for param in W_params: + self._params[param] = self._params.init((self.input_dim, self.hidden_dim)) + + for param in U_params: + self._params[param] = self.inner_init((self.hidden_dim, self.hidden_dim)) + + for param in b_params: + self._params[param] = np.full((self.hidden_dim,), self._params.initial_bias) + + # Combine weights for simplicity + self.W = [self._params[param] for param in W_params] + self.U = [self._params[param] for param in U_params] + + # Init gradient arrays for all weights + self._params.init_grad() + + self.hprev = np.zeros((x_shape[0], self.hidden_dim)) + self.oprev = np.zeros((x_shape[0], self.hidden_dim)) + + def forward_pass(self, X): + n_samples, n_timesteps, input_shape = X.shape + p = self._params + self.last_input = X + + self.states = np.zeros((n_samples, n_timesteps + 1, self.hidden_dim)) + self.outputs = np.zeros((n_samples, n_timesteps + 1, self.hidden_dim)) + self.gates = { + k: np.zeros((n_samples, n_timesteps, self.hidden_dim)) + for k in ["i", "f", "o", "c"] + } + + self.states[:, -1, :] = self.hprev + self.outputs[:, -1, :] = self.oprev + + for i in range(n_timesteps): + t_gates = np.dot(X[:, i, :], self.W) + np.dot( + self.outputs[:, i - 1, :], self.U + ) + + # Input + self.gates["i"][:, i, :] = sigmoid(t_gates[:, 0, :] + p["b_i"]) + # Forget + self.gates["f"][:, i, :] = sigmoid(t_gates[:, 1, :] + p["b_f"]) + # Output + self.gates["o"][:, i, :] = sigmoid(t_gates[:, 2, :] + p["b_o"]) + # Cell + self.gates["c"][:, i, :] = self.activation(t_gates[:, 3, :] + p["b_c"]) + + # (previous state * forget) + input + cell + self.states[:, i, :] = ( + self.states[:, i - 1, :] * self.gates["f"][:, i, :] + + self.gates["i"][:, i, :] * self.gates["c"][:, i, :] + ) + self.outputs[:, i, :] = self.gates["o"][:, i, :] * self.activation( + self.states[:, i, :] + ) + + self.hprev = self.states[:, n_timesteps - 1, :].copy() + self.oprev = self.outputs[:, n_timesteps - 1, :].copy() + + if self.return_sequences: + return self.outputs[:, 0:-1, :] + else: + return self.outputs[:, -2, :] + + def backward_pass(self, delta): + if len(delta.shape) == 2: + delta = delta[:, np.newaxis, :] + + n_samples, n_timesteps, input_shape = delta.shape + + # Temporal gradient arrays + grad = {k: np.zeros_like(self._params[k]) for k in self._params.keys()} + + dh_next = np.zeros((n_samples, input_shape)) + output = np.zeros((n_samples, n_timesteps, self.input_dim)) + + # Backpropagation through time + for i in reversed(range(n_timesteps)): + dhi = ( + delta[:, i, :] + * self.gates["o"][:, i, :] + * self.activation_d(self.states[:, i, :]) + + dh_next + ) + + og = delta[:, i, :] * self.activation(self.states[:, i, :]) + de_o = og * self.sigmoid_d(self.gates["o"][:, i, :]) + + grad["W_o"] += np.dot(self.last_input[:, i, :].T, de_o) + grad["U_o"] += np.dot(self.outputs[:, i - 1, :].T, de_o) + grad["b_o"] += de_o.sum(axis=0) + + de_f = (dhi * self.states[:, i - 1, :]) * self.sigmoid_d( + self.gates["f"][:, i, :] + ) + grad["W_f"] += np.dot(self.last_input[:, i, :].T, de_f) + grad["U_f"] += np.dot(self.outputs[:, i - 1, :].T, de_f) + grad["b_f"] += de_f.sum(axis=0) + + de_i = (dhi * self.gates["c"][:, i, :]) * self.sigmoid_d( + self.gates["i"][:, i, :] + ) + grad["W_i"] += np.dot(self.last_input[:, i, :].T, de_i) + grad["U_i"] += np.dot(self.outputs[:, i - 1, :].T, de_i) + grad["b_i"] += de_i.sum(axis=0) + + de_c = (dhi * self.gates["i"][:, i, :]) * self.activation_d( + self.gates["c"][:, i, :] + ) + grad["W_c"] += np.dot(self.last_input[:, i, :].T, de_c) + grad["U_c"] += np.dot(self.outputs[:, i - 1, :].T, de_c) + grad["b_c"] += de_c.sum(axis=0) + + dh_next = dhi * self.gates["f"][:, i, :] + + # TODO: propagate error to the next layer + + # Change actual gradient arrays + for k in grad.keys(): + self._params.update_grad(k, grad[k]) + return output + + def shape(self, x_shape): + if self.return_sequences: + return x_shape[0], x_shape[1], self.hidden_dim + else: + return x_shape[0], self.hidden_dim diff --git a/mla/neuralnet/layers/recurrent/rnn.py b/mla/neuralnet/layers/recurrent/rnn.py new file mode 100644 index 0000000..232daf1 --- /dev/null +++ b/mla/neuralnet/layers/recurrent/rnn.py @@ -0,0 +1,110 @@ +# coding:utf-8 +import autograd.numpy as np +from autograd import elementwise_grad + +from mla.neuralnet.initializations import get_initializer +from mla.neuralnet.layers import Layer, get_activation, ParamMixin +from mla.neuralnet.parameters import Parameters + + +class RNN(Layer, ParamMixin): + """Vanilla RNN.""" + + def __init__( + self, + hidden_dim, + activation="tanh", + inner_init="orthogonal", + parameters=None, + return_sequences=True, + ): + self.return_sequences = return_sequences + self.hidden_dim = hidden_dim + self.inner_init = get_initializer(inner_init) + self.activation = get_activation(activation) + self.activation_d = elementwise_grad(self.activation) + if parameters is None: + self._params = Parameters() + else: + self._params = parameters + self.last_input = None + self.states = None + self.hprev = None + self.input_dim = None + + def setup(self, x_shape): + """ + Parameters + ---------- + x_shape : np.array(batch size, time steps, input shape) + """ + self.input_dim = x_shape[2] + + # Input -> Hidden + self._params["W"] = self._params.init((self.input_dim, self.hidden_dim)) + # Bias + self._params["b"] = np.full((self.hidden_dim,), self._params.initial_bias) + # Hidden -> Hidden layer + self._params["U"] = self.inner_init((self.hidden_dim, self.hidden_dim)) + + # Init gradient arrays + self._params.init_grad() + + self.hprev = np.zeros((x_shape[0], self.hidden_dim)) + + def forward_pass(self, X): + self.last_input = X + n_samples, n_timesteps, input_shape = X.shape + states = np.zeros((n_samples, n_timesteps + 1, self.hidden_dim)) + states[:, -1, :] = self.hprev.copy() + p = self._params + + for i in range(n_timesteps): + states[:, i, :] = np.tanh( + np.dot(X[:, i, :], p["W"]) + + np.dot(states[:, i - 1, :], p["U"]) + + p["b"] + ) + + self.states = states + self.hprev = states[:, n_timesteps - 1, :].copy() + if self.return_sequences: + return states[:, 0:-1, :] + else: + return states[:, -2, :] + + def backward_pass(self, delta): + if len(delta.shape) == 2: + delta = delta[:, np.newaxis, :] + n_samples, n_timesteps, input_shape = delta.shape + p = self._params + + # Temporal gradient arrays + grad = {k: np.zeros_like(p[k]) for k in p.keys()} + + dh_next = np.zeros((n_samples, input_shape)) + output = np.zeros((n_samples, n_timesteps, self.input_dim)) + + # Backpropagation through time + for i in reversed(range(n_timesteps)): + dhi = self.activation_d(self.states[:, i, :]) * (delta[:, i, :] + dh_next) + + grad["W"] += np.dot(self.last_input[:, i, :].T, dhi) + grad["b"] += delta[:, i, :].sum(axis=0) + grad["U"] += np.dot(self.states[:, i - 1, :].T, dhi) + + dh_next = np.dot(dhi, p["U"].T) + + d = np.dot(delta[:, i, :], p["U"].T) + output[:, i, :] = np.dot(d, p["W"].T) + + # Change actual gradient arrays + for k in grad.keys(): + self._params.update_grad(k, grad[k]) + return output + + def shape(self, x_shape): + if self.return_sequences: + return x_shape[0], x_shape[1], self.hidden_dim + else: + return x_shape[0], self.hidden_dim diff --git a/mla/neuralnet/loss.py b/mla/neuralnet/loss.py new file mode 100644 index 0000000..30def7e --- /dev/null +++ b/mla/neuralnet/loss.py @@ -0,0 +1,11 @@ +from ..metrics import mse, logloss, mae, hinge, binary_crossentropy + +categorical_crossentropy = logloss + + +def get_loss(name): + """Returns loss function by the name.""" + try: + return globals()[name] + except KeyError: + raise ValueError("Invalid metric function.") diff --git a/mla/neuralnet/nnet.py b/mla/neuralnet/nnet.py new file mode 100644 index 0000000..c39b96b --- /dev/null +++ b/mla/neuralnet/nnet.py @@ -0,0 +1,181 @@ +import logging + +import numpy as np +from autograd import elementwise_grad + +from mla.base import BaseEstimator +from mla.metrics.metrics import get_metric +from mla.neuralnet.layers import PhaseMixin +from mla.neuralnet.loss import get_loss +from mla.utils import batch_iterator + +np.random.seed(9999) + +""" +Architecture inspired from: + + https://github.com/fchollet/keras + https://github.com/andersbll/deeppy +""" + + +class NeuralNet(BaseEstimator): + fit_required = False + + def __init__( + self, + layers, + optimizer, + loss, + max_epochs=10, + batch_size=64, + metric="mse", + shuffle=False, + verbose=True, + ): + self.verbose = verbose + self.shuffle = shuffle + self.optimizer = optimizer + + self.loss = get_loss(loss) + + # TODO: fix + if loss == "categorical_crossentropy": + self.loss_grad = lambda actual, predicted: -(actual - predicted) + else: + self.loss_grad = elementwise_grad(self.loss, 1) + self.metric = get_metric(metric) + self.layers = layers + self.batch_size = batch_size + self.max_epochs = max_epochs + self._n_layers = 0 + self.log_metric = True if loss != metric else False + self.metric_name = metric + self.bprop_entry = self._find_bprop_entry() + self.training = False + self._initialized = False + + def _setup_layers(self, x_shape): + """Initialize model's layers.""" + x_shape = list(x_shape) + x_shape[0] = self.batch_size + + for layer in self.layers: + layer.setup(x_shape) + x_shape = layer.shape(x_shape) + + self._n_layers = len(self.layers) + # Setup optimizer + self.optimizer.setup(self) + self._initialized = True + logging.info("Total parameters: %s" % self.n_params) + + def _find_bprop_entry(self): + """Find entry layer for back propagation.""" + + if len(self.layers) > 0 and not hasattr(self.layers[-1], "parameters"): + return -1 + return len(self.layers) + + def fit(self, X, y=None): + if not self._initialized: + self._setup_layers(X.shape) + + if y.ndim == 1: + # Reshape vector to matrix + y = y[:, np.newaxis] + self._setup_input(X, y) + + self.is_training = True + # Pass neural network instance to an optimizer + self.optimizer.optimize(self) + self.is_training = False + + def update(self, X, y): + # Forward pass + y_pred = self.fprop(X) + + # Backward pass + grad = self.loss_grad(y, y_pred) + for layer in reversed(self.layers[: self.bprop_entry]): + grad = layer.backward_pass(grad) + return self.loss(y, y_pred) + + def fprop(self, X): + """Forward propagation.""" + for layer in self.layers: + X = layer.forward_pass(X) + return X + + def _predict(self, X=None): + if not self._initialized: + self._setup_layers(X.shape) + + y = [] + X_batch = batch_iterator(X, self.batch_size) + for Xb in X_batch: + y.append(self.fprop(Xb)) + return np.concatenate(y) + + @property + def parametric_layers(self): + for layer in self.layers: + if hasattr(layer, "parameters"): + yield layer + + @property + def parameters(self): + """Returns a list of all parameters.""" + params = [] + for layer in self.parametric_layers: + params.append(layer.parameters) + return params + + def error(self, X=None, y=None): + """Calculate an error for given examples.""" + training_phase = self.is_training + if training_phase: + # Temporally disable training. + # Some layers work differently while training (e.g. Dropout). + self.is_training = False + if X is None and y is None: + y_pred = self._predict(self.X) + score = self.metric(self.y, y_pred) + else: + y_pred = self._predict(X) + score = self.metric(y, y_pred) + if training_phase: + self.is_training = True + return score + + @property + def is_training(self): + return self.training + + @is_training.setter + def is_training(self, train): + self.training = train + for layer in self.layers: + if isinstance(layer, PhaseMixin): + layer.is_training = train + + def shuffle_dataset(self): + """Shuffle rows in the dataset.""" + n_samples = self.X.shape[0] + indices = np.arange(n_samples) + np.random.shuffle(indices) + self.X = self.X.take(indices, axis=0) + self.y = self.y.take(indices, axis=0) + + @property + def n_layers(self): + """Returns the number of layers.""" + return self._n_layers + + @property + def n_params(self): + """Return the number of trainable parameters.""" + return sum([layer.parameters.n_params for layer in self.parametric_layers]) + + def reset(self): + self._initialized = False diff --git a/mla/neuralnet/optimizers.py b/mla/neuralnet/optimizers.py new file mode 100644 index 0000000..1e2a68a --- /dev/null +++ b/mla/neuralnet/optimizers.py @@ -0,0 +1,251 @@ +import logging +import time +from collections import defaultdict + +import numpy as np +from tqdm import tqdm + +from mla.utils import batch_iterator + +""" +References: + + Gradient descent optimization algorithms https://ruder.io/optimizing-gradient-descent/ +""" + + +class Optimizer(object): + def optimize(self, network): + loss_history = [] + for i in range(network.max_epochs): + if network.shuffle: + network.shuffle_dataset() + + start_time = time.time() + loss = self.train_epoch(network) + loss_history.append(loss) + if network.verbose: + msg = "Epoch:%s, train loss: %s" % (i, loss) + if network.log_metric: + msg += ", train %s: %s" % (network.metric_name, network.error()) + msg += ", elapsed: %s sec." % (time.time() - start_time) + logging.info(msg) + return loss_history + + def update(self, network): + """Performs an update of parameters.""" + raise NotImplementedError + + def train_epoch(self, network): + losses = [] + + # Create batch iterator + X_batch = batch_iterator(network.X, network.batch_size) + y_batch = batch_iterator(network.y, network.batch_size) + + batch = zip(X_batch, y_batch) + if network.verbose: + batch = tqdm( + batch, total=int(np.ceil(network.n_samples / network.batch_size)) + ) + + for X, y in batch: + loss = np.mean(network.update(X, y)) + self.update(network) + losses.append(loss) + + epoch_loss = np.mean(losses) + return epoch_loss + + def train_batch(self, network, X, y): + loss = np.mean(network.update(X, y)) + self.update(network) + return loss + + def setup(self, network): + """Creates additional variables. + Note: Must be called before optimization process.""" + raise NotImplementedError + + +class SGD(Optimizer): + def __init__(self, learning_rate=0.01, momentum=0.9, decay=0.0, nesterov=False): + self.nesterov = nesterov + self.decay = decay + self.momentum = momentum + self.lr = learning_rate + self.iteration = 0 + self.velocity = None + + def update(self, network): + lr = self.lr * (1.0 / (1.0 + self.decay * self.iteration)) + + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + # Get gradient values + grad = layer.parameters.grad[n] + update = self.momentum * self.velocity[i][n] - lr * grad + self.velocity[i][n] = update + if self.nesterov: + # Adjust using updated velocity + update = self.momentum * self.velocity[i][n] - lr * grad + layer.parameters.step(n, update) + self.iteration += 1 + + def setup(self, network): + self.velocity = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.velocity[i][n] = np.zeros_like(layer.parameters[n]) + + +class Adagrad(Optimizer): + def __init__(self, learning_rate=0.01, epsilon=1e-8): + self.eps = epsilon + self.lr = learning_rate + + def update(self, network): + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + grad = layer.parameters.grad[n] + self.accu[i][n] += grad**2 + step = self.lr * grad / (np.sqrt(self.accu[i][n]) + self.eps) + layer.parameters.step(n, -step) + + def setup(self, network): + # Accumulators + self.accu = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.accu[i][n] = np.zeros_like(layer.parameters[n]) + + +class Adadelta(Optimizer): + def __init__(self, learning_rate=1.0, rho=0.95, epsilon=1e-8): + self.rho = rho + self.eps = epsilon + self.lr = learning_rate + + def update(self, network): + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + grad = layer.parameters.grad[n] + self.accu[i][n] = ( + self.rho * self.accu[i][n] + (1.0 - self.rho) * grad**2 + ) + step = ( + grad + * np.sqrt(self.d_accu[i][n] + self.eps) + / np.sqrt(self.accu[i][n] + self.eps) + ) + + layer.parameters.step(n, -step * self.lr) + # Update delta accumulator + self.d_accu[i][n] = ( + self.rho * self.d_accu[i][n] + (1.0 - self.rho) * step**2 + ) + + def setup(self, network): + # Accumulators + self.accu = defaultdict(dict) + self.d_accu = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.accu[i][n] = np.zeros_like(layer.parameters[n]) + self.d_accu[i][n] = np.zeros_like(layer.parameters[n]) + + +class RMSprop(Optimizer): + def __init__(self, learning_rate=0.001, rho=0.9, epsilon=1e-8): + self.eps = epsilon + self.rho = rho + self.lr = learning_rate + + def update(self, network): + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + grad = layer.parameters.grad[n] + self.accu[i][n] = (self.rho * self.accu[i][n]) + (1.0 - self.rho) * ( + grad**2 + ) + step = self.lr * grad / (np.sqrt(self.accu[i][n]) + self.eps) + layer.parameters.step(n, -step) + + def setup(self, network): + # Accumulators + self.accu = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.accu[i][n] = np.zeros_like(layer.parameters[n]) + + +class Adam(Optimizer): + def __init__(self, learning_rate=0.001, beta_1=0.9, beta_2=0.999, epsilon=1e-8): + self.epsilon = epsilon + self.beta_2 = beta_2 + self.beta_1 = beta_1 + self.lr = learning_rate + self.iterations = 0 + self.t = 1 + + def update(self, network): + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + grad = layer.parameters.grad[n] + self.ms[i][n] = (self.beta_1 * self.ms[i][n]) + ( + 1.0 - self.beta_1 + ) * grad + self.vs[i][n] = (self.beta_2 * self.vs[i][n]) + ( + 1.0 - self.beta_2 + ) * grad**2 + lr = ( + self.lr + * np.sqrt(1.0 - self.beta_2**self.t) + / (1.0 - self.beta_1**self.t) + ) + + step = lr * self.ms[i][n] / (np.sqrt(self.vs[i][n]) + self.epsilon) + layer.parameters.step(n, -step) + self.t += 1 + + def setup(self, network): + # Accumulators + self.ms = defaultdict(dict) + self.vs = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.ms[i][n] = np.zeros_like(layer.parameters[n]) + self.vs[i][n] = np.zeros_like(layer.parameters[n]) + + +class Adamax(Optimizer): + def __init__(self, learning_rate=0.002, beta_1=0.9, beta_2=0.999, epsilon=1e-8): + self.epsilon = epsilon + self.beta_2 = beta_2 + self.beta_1 = beta_1 + self.lr = learning_rate + self.t = 1 + + def update(self, network): + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + grad = layer.parameters.grad[n] + self.ms[i][n] = self.beta_1 * self.ms[i][n] + (1.0 - self.beta_1) * grad + self.us[i][n] = np.maximum(self.beta_2 * self.us[i][n], np.abs(grad)) + + step = ( + self.lr + / (1 - self.beta_1**self.t) + * self.ms[i][n] + / (self.us[i][n] + self.epsilon) + ) + layer.parameters.step(n, -step) + self.t += 1 + + def setup(self, network): + self.ms = defaultdict(dict) + self.us = defaultdict(dict) + for i, layer in enumerate(network.parametric_layers): + for n in layer.parameters.keys(): + self.ms[i][n] = np.zeros_like(layer.parameters[n]) + self.us[i][n] = np.zeros_like(layer.parameters[n]) diff --git a/mla/neuralnet/parameters.py b/mla/neuralnet/parameters.py new file mode 100644 index 0000000..e81f18d --- /dev/null +++ b/mla/neuralnet/parameters.py @@ -0,0 +1,98 @@ +# coding:utf-8 +import numpy as np + +from mla.neuralnet.initializations import get_initializer + + +class Parameters(object): + def __init__( + self, + init="glorot_uniform", + scale=0.5, + bias=1.0, + regularizers=None, + constraints=None, + ): + """A container for layer's parameters. + + Parameters + ---------- + init : str, default 'glorot_uniform'. + The name of the weight initialization function. + scale : float, default 0.5 + bias : float, default 1.0 + Initial values for bias. + regularizers : dict + Weight regularizers. + >>> {'W' : L2()} + constraints : dict + Weight constraints. + >>> {'b' : MaxNorm()} + """ + if constraints is None: + self.constraints = {} + else: + self.constraints = constraints + + if regularizers is None: + self.regularizers = {} + else: + self.regularizers = regularizers + + self.initial_bias = bias + self.scale = scale + self.init = get_initializer(init) + + self._params = {} + self._grads = {} + + def setup_weights(self, W_shape, b_shape=None): + if "W" not in self._params: + self._params["W"] = self.init(shape=W_shape, scale=self.scale) + if b_shape is None: + self._params["b"] = np.full(W_shape[1], self.initial_bias) + else: + self._params["b"] = np.full(b_shape, self.initial_bias) + self.init_grad() + + def init_grad(self): + """Init gradient arrays corresponding to each weight array.""" + for key in self._params.keys(): + if key not in self._grads: + self._grads[key] = np.zeros_like(self._params[key]) + + def step(self, name, step): + """Increase specific weight by amount of the step parameter.""" + self._params[name] += step + + if name in self.constraints: + self._params[name] = self.constraints[name].clip(self._params[name]) + + def update_grad(self, name, value): + """Update gradient values.""" + self._grads[name] = value + + if name in self.regularizers: + self._grads[name] += self.regularizers[name](self._params[name]) + + @property + def n_params(self): + """Count the number of parameters in this layer.""" + return sum([np.prod(self._params[x].shape) for x in self._params.keys()]) + + def keys(self): + return self._params.keys() + + @property + def grad(self): + return self._grads + + # Allow access to the fields using dict syntax, e.g. parameters['W'] + def __getitem__(self, item): + if item in self._params: + return self._params[item] + else: + raise ValueError + + def __setitem__(self, key, value): + self._params[key] = value diff --git a/mla/neuralnet/regularizers.py b/mla/neuralnet/regularizers.py new file mode 100644 index 0000000..723ccce --- /dev/null +++ b/mla/neuralnet/regularizers.py @@ -0,0 +1,35 @@ +# coding:utf-8 +import numpy as np +from autograd import elementwise_grad + + +class Regularizer(object): + def __init__(self, C=0.01): + self.C = C + self._grad = elementwise_grad(self._penalty) + + def _penalty(self, weights): + raise NotImplementedError() + + def grad(self, weights): + return self._grad(weights) + + def __call__(self, weights): + return self.grad(weights) + + +class L1(Regularizer): + def _penalty(self, weights): + return self.C * np.abs(weights) + + +class L2(Regularizer): + def _penalty(self, weights): + return self.C * weights**2 + + +class ElasticNet(Regularizer): + """Linear combination of L1 and L2 penalties.""" + + def _penalty(self, weights): + return 0.5 * self.C * weights**2 + (1.0 - self.C) * np.abs(weights) diff --git a/mla/neuralnet/tests/test_activations.py b/mla/neuralnet/tests/test_activations.py new file mode 100644 index 0000000..7bb095a --- /dev/null +++ b/mla/neuralnet/tests/test_activations.py @@ -0,0 +1,21 @@ +import sys + +import numpy as np + +from mla.neuralnet.activations import * + + +def test_softplus(): + # np.exp(z_max) will overflow + z_max = np.log(sys.float_info.max) + 1.0e10 + # 1.0 / np.exp(z_min) will overflow + z_min = np.log(sys.float_info.min) - 1.0e10 + inputs = np.array([0.0, 1.0, -1.0, z_min, z_max]) + # naive implementation of np.log(1 + np.exp(z_max)) will overflow + # naive implementation of z + np.log(1 + 1 / np.exp(z_min)) will + # throw ZeroDivisionError + outputs = np.array( + [np.log(2.0), np.log1p(np.exp(1.0)), np.log1p(np.exp(-1.0)), 0.0, z_max] + ) + + assert np.allclose(outputs, softplus(inputs)) diff --git a/mla/neuralnet/tests/test_optimizers.py b/mla/neuralnet/tests/test_optimizers.py new file mode 100644 index 0000000..0c9c7d8 --- /dev/null +++ b/mla/neuralnet/tests/test_optimizers.py @@ -0,0 +1,72 @@ +from sklearn.datasets import make_classification +from sklearn.metrics import roc_auc_score +from sklearn.model_selection import train_test_split + +from mla.neuralnet import NeuralNet +from mla.neuralnet.layers import Dense, Activation, Dropout, Parameters +from mla.neuralnet.optimizers import * +from mla.utils import one_hot + + +def clasifier(optimizer): + X, y = make_classification( + n_samples=1000, + n_features=100, + n_informative=75, + random_state=1111, + n_classes=2, + class_sep=2.5, + ) + y = one_hot(y) + + X -= np.mean(X, axis=0) + X /= np.std(X, axis=0) + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.15, random_state=1111 + ) + + model = NeuralNet( + layers=[ + Dense(128, Parameters(init="uniform")), + Activation("relu"), + Dropout(0.5), + Dense(64, Parameters(init="normal")), + Activation("relu"), + Dense(2), + Activation("softmax"), + ], + loss="categorical_crossentropy", + optimizer=optimizer, + metric="accuracy", + batch_size=64, + max_epochs=10, + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + return roc_auc_score(y_test[:, 0], predictions[:, 0]) + + +def test_adadelta(): + assert clasifier(Adadelta()) > 0.9 + + +def test_adam(): + assert clasifier(Adam()) > 0.9 + + +def test_adamax(): + assert clasifier(Adamax()) > 0.9 + + +def test_rmsprop(): + assert clasifier(RMSprop()) > 0.9 + + +def test_adagrad(): + assert clasifier(Adagrad()) > 0.9 + + +def test_sgd(): + assert clasifier(SGD(learning_rate=0.0001)) > 0.9 + assert clasifier(SGD(learning_rate=0.0001, nesterov=True, momentum=0.9)) > 0.9 + assert clasifier(SGD(learning_rate=0.0001, nesterov=False, momentum=0.0)) > 0.9 diff --git a/mla/pca.py b/mla/pca.py new file mode 100644 index 0000000..9155f91 --- /dev/null +++ b/mla/pca.py @@ -0,0 +1,63 @@ +# coding:utf-8 +import logging + +import numpy as np +from scipy.linalg import svd + +from mla.base import BaseEstimator + +np.random.seed(1000) + + +class PCA(BaseEstimator): + y_required = False + + def __init__(self, n_components, solver="svd"): + """Principal component analysis (PCA) implementation. + + Transforms a dataset of possibly correlated values into n linearly + uncorrelated components. The components are ordered such that the first + has the largest possible variance and each following component as the + largest possible variance given the previous components. This causes + the early components to contain most of the variability in the dataset. + + Parameters + ---------- + n_components : int + solver : str, default 'svd' + {'svd', 'eigen'} + """ + self.solver = solver + self.n_components = n_components + self.components = None + self.mean = None + + def fit(self, X, y=None): + self.mean = np.mean(X, axis=0) + self._decompose(X) + + def _decompose(self, X): + # Mean centering + X = X.copy() + X -= self.mean + + if self.solver == "svd": + _, s, Vh = svd(X, full_matrices=True) + elif self.solver == "eigen": + s, Vh = np.linalg.eig(np.cov(X.T)) + Vh = Vh.T + + s_squared = s**2 + variance_ratio = s_squared / s_squared.sum() + logging.info( + "Explained variance ratio: %s" % (variance_ratio[0 : self.n_components]) + ) + self.components = Vh[0 : self.n_components] + + def transform(self, X): + X = X.copy() + X -= self.mean + return np.dot(X, self.components.T) + + def _predict(self, X=None): + return self.transform(X) diff --git a/mla/rbm.py b/mla/rbm.py new file mode 100644 index 0000000..90143b7 --- /dev/null +++ b/mla/rbm.py @@ -0,0 +1,101 @@ +# coding:utf-8 +import logging + +import numpy as np +from scipy.special import expit + +from mla.base import BaseEstimator +from mla.utils import batch_iterator + +np.random.seed(9999) +sigmoid = expit + +""" +References: +A Practical Guide to Training Restricted Boltzmann Machines https://www.cs.toronto.edu/~hinton/absps/guideTR.pdf +""" + + +class RBM(BaseEstimator): + y_required = False + + def __init__(self, n_hidden=128, learning_rate=0.1, batch_size=10, max_epochs=100): + """Bernoulli Restricted Boltzmann Machine (RBM) + + Parameters + ---------- + + n_hidden : int, default 128 + The number of hidden units. + learning_rate : float, default 0.1 + batch_size : int, default 10 + max_epochs : int, default 100 + """ + self.max_epochs = max_epochs + self.batch_size = batch_size + self.lr = learning_rate + self.n_hidden = n_hidden + + def fit(self, X, y=None): + self.n_visible = X.shape[1] + self._init_weights() + self._setup_input(X, y) + self._train() + + def _init_weights(self): + self.W = np.random.randn(self.n_visible, self.n_hidden) * 0.1 + + # Bias for visible and hidden units + self.bias_v = np.zeros(self.n_visible, dtype=np.float32) + self.bias_h = np.zeros(self.n_hidden, dtype=np.float32) + + self.errors = [] + + def _train(self): + """Use CD-1 training procedure, basically an exact inference for `positive_associations`, + followed by a "non burn-in" block Gibbs Sampling for the `negative_associations`.""" + + for i in range(self.max_epochs): + error = 0 + for batch in batch_iterator(self.X, batch_size=self.batch_size): + positive_hidden = sigmoid(np.dot(batch, self.W) + self.bias_h) + hidden_states = self._sample(positive_hidden) # sample hidden state h1 + positive_associations = np.dot(batch.T, positive_hidden) + + negative_visible = sigmoid( + np.dot(hidden_states, self.W.T) + self.bias_v + ) + negative_visible = self._sample( + negative_visible + ) # use the sampled hidden state h1 to sample v1 + negative_hidden = sigmoid( + np.dot(negative_visible, self.W) + self.bias_h + ) + negative_associations = np.dot(negative_visible.T, negative_hidden) + + lr = self.lr / float(batch.shape[0]) + self.W += lr * ( + (positive_associations - negative_associations) + / float(self.batch_size) + ) + self.bias_h += lr * ( + negative_hidden.sum(axis=0) - negative_associations.sum(axis=0) + ) + self.bias_v += lr * ( + np.asarray(batch.sum(axis=0)).squeeze() + - negative_visible.sum(axis=0) + ) + + error += np.sum((batch - negative_visible) ** 2) + + self.errors.append(error) + logging.info("Iteration %s, error %s" % (i, error)) + logging.debug("Weights: %s" % self.W) + logging.debug("Hidden bias: %s" % self.bias_h) + logging.debug("Visible bias: %s" % self.bias_v) + + def _sample(self, X): + return X > np.random.random_sample(size=X.shape) + + def _predict(self, X=None): + return sigmoid(np.dot(X, self.W) + self.bias_h) diff --git a/mla/rl/__init__.py b/mla/rl/__init__.py new file mode 100644 index 0000000..f512dea --- /dev/null +++ b/mla/rl/__init__.py @@ -0,0 +1 @@ +# coding:utf-8 diff --git a/mla/rl/dqn.py b/mla/rl/dqn.py new file mode 100644 index 0000000..42b5809 --- /dev/null +++ b/mla/rl/dqn.py @@ -0,0 +1,158 @@ +# coding:utf-8 +import logging +import random + +import gym +import numpy as np +from gym import wrappers + +np.random.seed(9999) + +logger = logging.getLogger() +logger.setLevel(logging.INFO) + +""" +References: + Sutton, Barto (2017). Reinforcement Learning: An Introduction. MIT Press, Cambridge, MA. +""" + + +class DQN(object): + def __init__( + self, + n_episodes=500, + gamma=0.99, + batch_size=32, + epsilon=1.0, + decay=0.005, + min_epsilon=0.1, + memory_limit=500, + ): + """Deep Q learning implementation. + + Parameters + ---------- + + min_epsilon : float + Minimal value for epsilon. + epsilon : float + ε-greedy value. + decay : float + Epsilon decay rate. + memory_limit : int + Limit of experience replay memory. + + """ + + self.memory_limit = memory_limit + self.min_epsilon = min_epsilon + self.gamma = gamma + self.epsilon = epsilon + self.n_episodes = n_episodes + self.batch_size = batch_size + self.decay = decay + + def init_environment(self, name="CartPole-v0", monitor=False): + self.env = gym.make(name) + if monitor: + self.env = wrappers.Monitor( + self.env, name, force=True, video_callable=False + ) + + self.n_states = self.env.observation_space.shape[0] + self.n_actions = self.env.action_space.n + + # Experience replay + self.replay = [] + + def init_model(self, model): + self.model = model(self.n_actions, self.batch_size) + + def train(self, render=False): + max_reward = 0 + + for ep in range(self.n_episodes): + state = self.env.reset() + + total_reward = 0 + + while True: + if render: + self.env.render() + + if np.random.rand() <= self.epsilon: + # Exploration + action = np.random.randint(self.n_actions) + else: + # Exploitation + action = np.argmax(self.model.predict(state[np.newaxis, :])[0]) + + # Run one timestep of the environment + new_state, reward, done, _ = self.env.step(action) + self.replay.append([state, action, reward, new_state, done]) + + # Sample batch from experience replay + batch_size = min(len(self.replay), self.batch_size) + batch = random.sample(self.replay, batch_size) + + X = np.zeros((batch_size, self.n_states)) + y = np.zeros((batch_size, self.n_actions)) + + states = np.array([b[0] for b in batch]) + new_states = np.array([b[3] for b in batch]) + + Q = self.model.predict(states) + new_Q = self.model.predict(new_states) + + # Construct training data + for i in range(batch_size): + state_r, action_r, reward_r, new_state_r, done_r = batch[i] + target = Q[i] + + if done_r: + target[action_r] = reward_r + else: + target[action_r] = reward_r + self.gamma * np.amax(new_Q[i]) + + X[i, :] = state_r + y[i, :] = target + + # Train deep learning model + self.model.fit(X, y) + + total_reward += reward + state = new_state + + if done: + # Exit from current episode + break + + # Remove old entries from replay memory + while len(self.replay) > self.memory_limit: + self.replay.pop(0) + + self.epsilon = self.min_epsilon + (1.0 - self.min_epsilon) * np.exp( + -self.decay * ep + ) + + max_reward = max(max_reward, total_reward) + logger.info( + "Episode: %s, reward %s, epsilon %s, max reward %s" + % (ep, total_reward, self.epsilon, max_reward) + ) + logging.info("Training finished.") + + def play(self, episodes): + for i in range(episodes): + state = self.env.reset() + total_reward = 0 + + while True: + self.env.render() + action = np.argmax(self.model.predict(state[np.newaxis, :])[0]) + state, reward, done, _ = self.env.step(action) + total_reward += reward + if done: + break + logger.info("Episode: %s, reward %s" % (i, total_reward)) + self.env.close() diff --git a/mla/svm/__init__.py b/mla/svm/__init__.py new file mode 100644 index 0000000..f512dea --- /dev/null +++ b/mla/svm/__init__.py @@ -0,0 +1 @@ +# coding:utf-8 diff --git a/mla/svm/kernerls.py b/mla/svm/kernerls.py new file mode 100644 index 0000000..da289a1 --- /dev/null +++ b/mla/svm/kernerls.py @@ -0,0 +1,35 @@ +# coding:utf-8 +import numpy as np +import scipy.spatial.distance as dist + + +class Linear(object): + def __call__(self, x, y): + return np.dot(x, y.T) + + def __repr__(self): + return "Linear kernel" + + +class Poly(object): + def __init__(self, degree=2): + self.degree = degree + + def __call__(self, x, y): + return np.dot(x, y.T) ** self.degree + + def __repr__(self): + return "Poly kernel" + + +class RBF(object): + def __init__(self, gamma=0.1): + self.gamma = gamma + + def __call__(self, x, y): + x = np.atleast_2d(x) + y = np.atleast_2d(y) + return np.exp(-self.gamma * dist.cdist(x, y) ** 2).flatten() + + def __repr__(self): + return "RBF kernel" diff --git a/mla/svm/svm.py b/mla/svm/svm.py new file mode 100644 index 0000000..a4b38ae --- /dev/null +++ b/mla/svm/svm.py @@ -0,0 +1,145 @@ +# coding:utf-8 +import logging + +import numpy as np + +from mla.base import BaseEstimator +from mla.svm.kernerls import Linear + +np.random.seed(9999) + +""" +References: +The Simplified SMO Algorithm http://cs229.stanford.edu/materials/smo.pdf +""" + + +class SVM(BaseEstimator): + def __init__(self, C=1.0, kernel=None, tol=1e-3, max_iter=100): + """Support vector machines implementation using simplified SMO optimization. + + Parameters + ---------- + C : float, default 1.0 + kernel : Kernel object + tol : float , default 1e-3 + max_iter : int, default 100 + """ + self.C = C + self.tol = tol + self.max_iter = max_iter + if kernel is None: + self.kernel = Linear() + else: + self.kernel = kernel + + self.b = 0 + self.alpha = None + self.K = None + + def fit(self, X, y=None): + self._setup_input(X, y) + self.K = np.zeros((self.n_samples, self.n_samples)) + for i in range(self.n_samples): + self.K[:, i] = self.kernel(self.X, self.X[i, :]) + self.alpha = np.zeros(self.n_samples) + self.sv_idx = np.arange(0, self.n_samples) + return self._train() + + def _train(self): + iters = 0 + while iters < self.max_iter: + iters += 1 + alpha_prev = np.copy(self.alpha) + + for j in range(self.n_samples): + # Pick random i + i = self.random_index(j) + + eta = 2.0 * self.K[i, j] - self.K[i, i] - self.K[j, j] + if eta >= 0: + continue + L, H = self._find_bounds(i, j) + + # Error for current examples + e_i, e_j = self._error(i), self._error(j) + + # Save old alphas + alpha_io, alpha_jo = self.alpha[i], self.alpha[j] + + # Update alpha + self.alpha[j] -= (self.y[j] * (e_i - e_j)) / eta + self.alpha[j] = self.clip(self.alpha[j], H, L) + + self.alpha[i] = self.alpha[i] + self.y[i] * self.y[j] * ( + alpha_jo - self.alpha[j] + ) + + # Find intercept + b1 = ( + self.b + - e_i + - self.y[i] * (self.alpha[i] - alpha_io) * self.K[i, i] + - self.y[j] * (self.alpha[j] - alpha_jo) * self.K[i, j] + ) + b2 = ( + self.b + - e_j + - self.y[j] * (self.alpha[j] - alpha_jo) * self.K[j, j] + - self.y[i] * (self.alpha[i] - alpha_io) * self.K[i, j] + ) + if 0 < self.alpha[i] < self.C: + self.b = b1 + elif 0 < self.alpha[j] < self.C: + self.b = b2 + else: + self.b = 0.5 * (b1 + b2) + + # Check convergence + diff = np.linalg.norm(self.alpha - alpha_prev) + if diff < self.tol: + break + logging.info("Convergence has reached after %s." % iters) + + # Save support vectors index + self.sv_idx = np.where(self.alpha > 0)[0] + + def _predict(self, X=None): + n = X.shape[0] + result = np.zeros(n) + for i in range(n): + result[i] = np.sign(self._predict_row(X[i, :])) + return result + + def _predict_row(self, X): + k_v = self.kernel(self.X[self.sv_idx], X) + return np.dot((self.alpha[self.sv_idx] * self.y[self.sv_idx]).T, k_v.T) + self.b + + def clip(self, alpha, H, L): + if alpha > H: + alpha = H + if alpha < L: + alpha = L + return alpha + + def _error(self, i): + """Error for single example.""" + return self._predict_row(self.X[i]) - self.y[i] + + def _find_bounds(self, i, j): + """Find L and H such that L <= alpha <= H. + Also, alpha must satisfy the constraint 0 <= αlpha <= C. + """ + if self.y[i] != self.y[j]: + L = max(0, self.alpha[j] - self.alpha[i]) + H = min(self.C, self.C - self.alpha[i] + self.alpha[j]) + else: + L = max(0, self.alpha[i] + self.alpha[j] - self.C) + H = min(self.C, self.alpha[i] + self.alpha[j]) + return L, H + + def random_index(self, z): + i = z + while i == z: + i = np.random.randint(0, self.n_samples - 1) + return i diff --git a/mla/tests/__init__.py b/mla/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/mla/tests/test_classification_accuracy.py b/mla/tests/test_classification_accuracy.py new file mode 100644 index 0000000..8698daa --- /dev/null +++ b/mla/tests/test_classification_accuracy.py @@ -0,0 +1,114 @@ +from sklearn.metrics import roc_auc_score + +from mla.ensemble import RandomForestClassifier +from mla.ensemble.gbm import GradientBoostingClassifier +from mla.knn import KNNClassifier +from mla.linear_models import LogisticRegression +from mla.metrics import accuracy +from mla.naive_bayes import NaiveBayesClassifier +from mla.neuralnet import NeuralNet +from mla.neuralnet.constraints import MaxNorm +from mla.neuralnet.layers import Activation, Dense, Dropout +from mla.neuralnet.optimizers import Adadelta +from mla.neuralnet.parameters import Parameters +from mla.neuralnet.regularizers import L2 +from mla.svm.kernerls import RBF, Linear +from mla.svm.svm import SVM +from mla.utils import one_hot + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_classification + +# Generate a random regression problem +X, y = make_classification( + n_samples=750, + n_features=10, + n_informative=8, + random_state=1111, + n_classes=2, + class_sep=2.5, + n_redundant=0, +) +X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.12, random_state=1111 +) + + +# All classifiers except convnet, RNN, LSTM. + + +def test_linear_model(): + model = LogisticRegression(lr=0.01, max_iters=500, penalty="l1", C=0.01) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + assert roc_auc_score(y_test, predictions) >= 0.95 + + +def test_random_forest(): + model = RandomForestClassifier(n_estimators=10, max_depth=4) + model.fit(X_train, y_train) + predictions = model.predict(X_test)[:, 1] + assert roc_auc_score(y_test, predictions) >= 0.95 + + +def test_svm_classification(): + y_signed_train = (y_train * 2) - 1 + y_signed_test = (y_test * 2) - 1 + + for kernel in [RBF(gamma=0.05), Linear()]: + model = SVM(max_iter=500, kernel=kernel) + model.fit(X_train, y_signed_train) + predictions = model.predict(X_test) + assert accuracy(y_signed_test, predictions) >= 0.8 + + +def test_mlp(): + y_train_onehot = one_hot(y_train) + y_test_onehot = one_hot(y_test) + + model = NeuralNet( + layers=[ + Dense(256, Parameters(init="uniform", regularizers={"W": L2(0.05)})), + Activation("relu"), + Dropout(0.5), + Dense(128, Parameters(init="normal", constraints={"W": MaxNorm()})), + Activation("relu"), + Dense(2), + Activation("softmax"), + ], + loss="categorical_crossentropy", + optimizer=Adadelta(), + metric="accuracy", + batch_size=64, + max_epochs=25, + ) + model.fit(X_train, y_train_onehot) + predictions = model.predict(X_test) + assert roc_auc_score(y_test_onehot[:, 0], predictions[:, 0]) >= 0.95 + + +def test_gbm(): + model = GradientBoostingClassifier( + n_estimators=25, max_depth=3, max_features=5, learning_rate=0.1 + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + assert roc_auc_score(y_test, predictions) >= 0.95 + + +def test_naive_bayes(): + model = NaiveBayesClassifier() + model.fit(X_train, y_train) + predictions = model.predict(X_test)[:, 1] + assert roc_auc_score(y_test, predictions) >= 0.95 + + +def test_knn(): + clf = KNNClassifier(k=5) + + clf.fit(X_train, y_train) + predictions = clf.predict(X_test) + assert accuracy(y_test, predictions) >= 0.95 diff --git a/mla/tests/test_reduction.py b/mla/tests/test_reduction.py new file mode 100644 index 0000000..b934614 --- /dev/null +++ b/mla/tests/test_reduction.py @@ -0,0 +1,46 @@ +# coding=utf-8 +import pytest +from sklearn.datasets import make_classification +from sklearn.metrics import roc_auc_score + +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split + +from mla.ensemble import RandomForestClassifier +from mla.pca import PCA + + +@pytest.fixture +def dataset(): + # Generate a random binary classification problem. + return make_classification( + n_samples=1000, + n_features=100, + n_informative=75, + random_state=1111, + n_classes=2, + class_sep=2.5, + ) + + +# TODO: fix +@pytest.mark.skip() +def test_PCA(dataset): + X, y = dataset + X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.25, random_state=1111 + ) + p = PCA(50, solver="eigen") + + # fit PCA with training set, not the entire dataset + p.fit(X_train) + X_train_reduced = p.transform(X_train) + X_test_reduced = p.transform(X_test) + + model = RandomForestClassifier(n_estimators=25, max_depth=5) + model.fit(X_train_reduced, y_train) + predictions = model.predict(X_test_reduced)[:, 1] + score = roc_auc_score(y_test, predictions) + assert score >= 0.75 diff --git a/mla/tests/test_regression_accuracy.py b/mla/tests/test_regression_accuracy.py new file mode 100644 index 0000000..33cf2f5 --- /dev/null +++ b/mla/tests/test_regression_accuracy.py @@ -0,0 +1,61 @@ +try: + from sklearn.model_selection import train_test_split +except ImportError: + from sklearn.cross_validation import train_test_split +from sklearn.datasets import make_regression + +from mla.knn import KNNRegressor +from mla.linear_models import LinearRegression +from mla.metrics.metrics import mean_squared_error +from mla.neuralnet import NeuralNet +from mla.neuralnet.layers import Activation, Dense +from mla.neuralnet.optimizers import Adam +from mla.neuralnet.parameters import Parameters + +# Generate a random regression problem +X, y = make_regression( + n_samples=1000, + n_features=10, + n_informative=10, + n_targets=1, + noise=0.05, + random_state=1111, + bias=0.5, +) +X_train, X_test, y_train, y_test = train_test_split( + X, y, test_size=0.25, random_state=1111 +) + + +def test_linear(): + model = LinearRegression(lr=0.01, max_iters=2000, penalty="l2", C=0.003) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + assert mean_squared_error(y_test, predictions) < 0.25 + + +def test_mlp(): + model = NeuralNet( + layers=[ + Dense(16, Parameters(init="normal")), + Activation("linear"), + Dense(8, Parameters(init="normal")), + Activation("linear"), + Dense(1), + ], + loss="mse", + optimizer=Adam(), + metric="mse", + batch_size=64, + max_epochs=150, + ) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + assert mean_squared_error(y_test, predictions.flatten()) < 1.0 + + +def test_knn(): + model = KNNRegressor(k=5) + model.fit(X_train, y_train) + predictions = model.predict(X_test) + assert mean_squared_error(y_test, predictions) < 10000 diff --git a/mla/tsne.py b/mla/tsne.py new file mode 100644 index 0000000..c2995d6 --- /dev/null +++ b/mla/tsne.py @@ -0,0 +1,136 @@ +# coding:utf-8 +import logging + +import numpy as np + +from mla.base import BaseEstimator +from mla.metrics.distance import l2_distance + +np.random.seed(999) + +""" +References: +https://lvdmaaten.github.io/tsne/ +Based on: +https://lvdmaaten.github.io/tsne/code/tsne_python.zip +""" + + +class TSNE(BaseEstimator): + y_required = False + + def __init__( + self, n_components=2, perplexity=30.0, max_iter=200, learning_rate=500 + ): + """A t-Distributed Stochastic Neighbor Embedding implementation. + + Parameters + ---------- + max_iter : int, default 200 + perplexity : float, default 30.0 + n_components : int, default 2 + """ + self.max_iter = max_iter + self.perplexity = perplexity + self.n_components = n_components + self.initial_momentum = 0.5 + self.final_momentum = 0.8 + self.min_gain = 0.01 + self.lr = learning_rate + self.tol = 1e-5 + self.perplexity_tries = 50 + + def fit_transform(self, X, y=None): + self._setup_input(X, y) + + Y = np.random.randn(self.n_samples, self.n_components) + velocity = np.zeros_like(Y) + gains = np.ones_like(Y) + + P = self._get_pairwise_affinities(X) + + iter_num = 0 + while iter_num < self.max_iter: + iter_num += 1 + + D = l2_distance(Y) + Q = self._q_distribution(D) + + # Normalizer q distribution + Q_n = Q / np.sum(Q) + + # Early exaggeration & momentum + pmul = 4.0 if iter_num < 100 else 1.0 + momentum = 0.5 if iter_num < 20 else 0.8 + + # Perform gradient step + grads = np.zeros(Y.shape) + for i in range(self.n_samples): + grad = 4 * np.dot((pmul * P[i] - Q_n[i]) * Q[i], Y[i] - Y) + grads[i] = grad + + gains = (gains + 0.2) * ((grads > 0) != (velocity > 0)) + (gains * 0.8) * ( + (grads > 0) == (velocity > 0) + ) + gains = gains.clip(min=self.min_gain) + + velocity = momentum * velocity - self.lr * (gains * grads) + Y += velocity + Y = Y - np.mean(Y, 0) + + error = np.sum(P * np.log(P / Q_n)) + logging.info("Iteration %s, error %s" % (iter_num, error)) + return Y + + def _get_pairwise_affinities(self, X): + """Computes pairwise affinities.""" + affines = np.zeros((self.n_samples, self.n_samples), dtype=np.float32) + target_entropy = np.log(self.perplexity) + distances = l2_distance(X) + + for i in range(self.n_samples): + affines[i, :] = self._binary_search(distances[i], target_entropy) + + # Fill diagonal with near zero value + np.fill_diagonal(affines, 1.0e-12) + + affines = affines.clip(min=1e-100) + affines = (affines + affines.T) / (2 * self.n_samples) + return affines + + def _binary_search(self, dist, target_entropy): + """Performs binary search to find suitable precision.""" + precision_min = 0 + precision_max = 1.0e15 + precision = 1.0e5 + + for _ in range(self.perplexity_tries): + denom = np.sum(np.exp(-dist[dist > 0.0] / precision)) + beta = np.exp(-dist / precision) / denom + + # Exclude zeros + g_beta = beta[beta > 0.0] + entropy = -np.sum(g_beta * np.log2(g_beta)) + + error = entropy - target_entropy + + if error > 0: + # Decrease precision + precision_max = precision + precision = (precision + precision_min) / 2.0 + else: + # Increase precision + precision_min = precision + precision = (precision + precision_max) / 2.0 + + if np.abs(error) < self.tol: + break + + return beta + + def _q_distribution(self, D): + """Computes Student t-distribution.""" + Q = 1.0 / (1.0 + D) + np.fill_diagonal(Q, 0.0) + Q = Q.clip(min=1e-100) + return Q diff --git a/mla/utils/__init__.py b/mla/utils/__init__.py new file mode 100644 index 0000000..7e45b8d --- /dev/null +++ b/mla/utils/__init__.py @@ -0,0 +1,3 @@ +# coding:utf-8 + +from .main import * diff --git a/mla/utils/main.py b/mla/utils/main.py new file mode 100644 index 0000000..37a07e7 --- /dev/null +++ b/mla/utils/main.py @@ -0,0 +1,25 @@ +# coding:utf-8 +import numpy as np + + +def one_hot(y): + n_values = np.max(y) + 1 + return np.eye(n_values)[y] + + +def batch_iterator(X, batch_size=64): + """Splits X into equal sized chunks.""" + n_samples = X.shape[0] + n_batches = n_samples // batch_size + batch_end = 0 + + for b in range(n_batches): + batch_begin = b * batch_size + batch_end = batch_begin + batch_size + + X_batch = X[batch_begin:batch_end] + + yield X_batch + + if n_batches * batch_size < n_samples: + yield X[batch_end:] diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..45f053d --- /dev/null +++ b/requirements.txt @@ -0,0 +1,8 @@ +tqdm +matplotlib>=1.5.1 +numpy>=1.11.1 +scikit-learn>=0.18 +scipy>=0.18.0 +seaborn>=0.7.1 +autograd>=1.1.7 +gym diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000..1e03675 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,8 @@ +[bdist_wheel] +universal=1 + +[metadata] +description-file=README.md + +[flake8] +max-line-length = 120 diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..11d2fe2 --- /dev/null +++ b/setup.py @@ -0,0 +1,35 @@ +from setuptools import setup, find_packages +from codecs import open +from os import path + +__version__ = '0.0.1' + +here = path.abspath(path.dirname(__file__)) + +# Get the long description from the README file +with open(path.join(here, 'README.md'), encoding='utf-8') as f: + long_description = f.read() + +# get the dependencies and installs +with open(path.join(here, 'requirements.txt'), encoding='utf-8') as f: + all_reqs = f.read().split('\n') + +install_requires = [x.strip() for x in all_reqs if 'git+' not in x] +dependency_links = [x.strip().replace('git+', '') for x in all_reqs if x.startswith('git+')] + +setup( + name='mla', + version=__version__, + description='A collection of minimal and clean implementations of machine learning algorithms.', + long_description=long_description, + url='https://github.com/rushter/mla', + download_url='https://github.com/rushter/mla/tarball/' + __version__, + license='MIT', + packages=find_packages(exclude=['docs', 'tests*']), + include_package_data=True, + author='Artem Golubin', + install_requires=install_requires, + setup_requires=['numpy>=1.10', 'scipy>=0.17'], + dependency_links=dependency_links, + author_email='gh@rushter.com' +)