{% set base = '.' %} {% set columns = data.columns.tolist() %} {% set CLASSIFICTION_MODELS = [ 'LogisticRegression', 'BernoulliNB', 'Perceptron', 'PassiveAggressiveClassifier', 'SVC', 'NuSVC', 'LinearSVC', 'KNeighborsClassifier', 'GaussianNB', 'DecisionTreeClassifier', 'RandomForestClassifier', 'MLPClassifier'] %} {% set REGRESSION_MODELS = [ 'LinearRegression', 'PassiveAggressiveRegressor', 'SVR', 'NuSVR', 'LinearSVR', 'KNeighborsRegressor', 'DecisionTreeRegressor', 'RandomForestRegressor', 'MLPRegressor'] %} {% set tcol = handler.store.load('target_col', False) %} {% set CLASSIFICTION_METRICS = { 'Accuracy': 'accuracy', 'Balanced Accuracy': 'balanced_accuracy', 'ROC AUC': 'roc_auc', 'F1 Score': 'f1_weighted' }%} {% set REGRESSION_METRICS = { 'R2': 'r2', 'Explained Variance': 'explained_variance', 'Max Error': 'max_error', 'Negative Mean Absolute Error': 'neg_mean_absolute_error', 'Negative Mean Squared Error': 'neg_mean_squared_error', 'Negative Root Mean Squared Error': 'neg_root_mean_squared_error' }%}
Train the Model
Pick a Target Column:
{% for col in columns %} {% set selected = "selected" if col == tcol else "" %}
{{ col }}
{% end %}
Columns to Exclude:
{% for col in columns %} {% set selected = "selected" if col in handler.store.load('exclude', []) else "" %}
{{ col }}
{% end %}
Categorical Columns:
{% for col in columns %} {% set selected = "selected" if col in handler.store.load('cats', []) else "" %}
{{ col }}
{% end %}
Numerical Columns:
{% for col in columns %} {% set selected = "selected" if col in handler.store.load('nums', []) else "" %}
{{ col }}
{% end %}
Transform:
Choose a Metric:
{% if handler.store.load('class') in CLASSIFICTION_MODELS %} {% for i, (mname, metric) in enumerate(CLASSIFICTION_METRICS.items()) %} {% set selected = "selected" if metric == "accuracy" else "" %}
{{ mname }}
{% if i == 0 %}
{% end %} {% end %} {% else %} {% for i, (mname, metric) in enumerate(REGRESSION_METRICS.items()) %} {% set selected = "selected" if metric == "r2" else "" %}
{{ mname }}
{% if i == 0 %}
{% end %} {% end %} {% end %}
Pick a Model:
{% for model in CLASSIFICTION_MODELS %} {% set selected = "selected" if model == handler.store.load('class') else "" %}
{{ model }}
{% end %}
{% for model in REGRESSION_MODELS %} {% set selected = "selected" if model == handler.store.load('class') else "" %}
{{ model }}
{% end %}
Train
Results
Your model scored
40%
Happy with the result?
Download the model.
Or get predictions:
Predict
Download Predictions
Make Predictions
Predict
<% COLS.forEach(function(col) { %>
<%= col.name %>
<% }) %>