# Changing L2 regularization constant in logistic regression proportionally to the number of columns/rows in the dataset

I'm trying to use scikit LogisticRegression to solve a multiclass text classification problem with variying number of columns (unigrams) in the trainging datasets. From what I understood, L2 regularization constant should change depending on the number of parameters in a model (L2 Regularization Constant). Is there any agreed formula/pattern to follow? Should it change linearly/exponentially, etc? Should the constant be increased or decreased when the number of columns increases? Does it also depend on the number of rows/observations?