I'm currently working on a data set where the goal is to predict the number of rented bikes in Seoul, given information about the weather at the time.
The data set can be downloaded here: https://archive.ics.uci.edu/dataset/560/seoul+bike+sharing+demand
One of the possible predictors is the variable rainfall, indicating the rainfall measured in millimetres at a given hour.
The distribution of that variable however is extremely skewed:
As you can see most of the observations had no rainfall at all, making the observations with rain almost invisible in the plot.
Applying a log-transformation didn't really improve the skewness too much:
Also using other transformation techniques like the Box-Cox-Tranformation didn't yield any desirable results.
What would be an appropriate way to transform or use a variable like this as a regressor for a linear regression model?
Thank you very much for your help!
EDIT:
Here is a histogram of only the positive values of rainfall:
And the distribution of the log of the positive values:
log1p
method is (highly) problematic, as discussed at stats.stackexchange.com/questions/30728. In my experience, rainfall is a challenging variable to analyze and requires a careful study of its distribution and of the data measurement process. $\endgroup$log1p
is that it uses a start value of $1.$ The thread I linked to explains why that is arbitrary and shows how bad it can be. $\endgroup$