Examples
import numpy as np
import pandas as pd
data = {'c_0': [7, -3, 0, -4, 5], 'c_1': [-2, -5, 6, 9, -5]}
df = pd.DataFrame(data)
df
Clips per column using lower and upper thresholds:
df.clip(-2, 6)
Clips using specific lower and upper thresholds per column element:
t = pd.Series([0, -4, -2, 5, 3])
t
df.clip(t, t + 2, axis=0)