Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

RMSE value from cross validation

# Perform cross-validation
scores = cross_val_score(model, X, y, cv=kf, scoring="neg_mean_squared_error")

# Calculate RMSE
rmse = np.sqrt(-scores)
print("Average RMSE: {}".format(np.mean(rmse)))
print("Standard Deviation of the target array: {}".format(np.std(y)))
Comment

PREVIOUS NEXT
Code Example
Python :: Sqlalchemy Define class from existing table 
Python :: python global lists 
Python :: from Player import Player 
Python :: add button to python gui file 
Python :: decision tree algorithm 
Python :: python divide all values in list 
Python :: twitter scraping python 
Python :: how to check if a key is present in python dictionary 
Python :: change group box border color pyqt5 
Python :: string remove ,replace, length in python 
Python :: k fold cross validation xgboost python 
Python :: sum() python 
Python :: python db access though ssh user 
Python :: sort decreasing python 
Python :: del df.loc 
Python :: get image data cv2 
Python :: how to install pywhatkit in pycharm 
Python :: check pd.NaT python 
Python :: python sound 
Python :: cv2.imwrite path 
Python :: python add to dictionary 
Python :: print index in for loop python 
Python :: docker run python 
Python :: django serializer get image list 
Python :: defaultdict in python 
Python :: pandas trim string of all cells 
Python :: SystemError: error return without exception set 
Python :: python math 
Python :: merge two arrays python 
Python :: get variable from function python 
ADD CONTENT
Topic
Content
Source link
Name
1+5 =