title: Export sklearn model to run in R
body: <p>I've built a random forest model using sklearn in Python. How can I export the model object <code>irisfit</code> so that it can be read in R and used to make predictions there? </p>
  
  <pre><code>import numpy as np
  import pandas as pd
  
  url = "https://archive.ics.uci.edu/ml/machine-learning-databases/iris/iris.data"
  names = ['sepal-length', 'sepal-width', 'petal-length', 'petal-width', 'class']
  iris = pd.read_csv(url, names=names)
  
  from sklearn.ensemble import RandomForestClassifier
  features = iris[['sepal-length', 'sepal-width', 'petal-length', 'petal-width']]
  target = iris['class']
  irisfit = RandomForestClassifier().fit(features, target)
  </code></pre>