Loading...

vastorbit.machine_learning.vast.linear_model.Ridge

class vastorbit.machine_learning.vast.linear_model.Ridge(name: str = None, overwrite_model: bool = False, **kwargs)

Creates a Ridge object using scikit-learn for training and the scalability of VAST DataBase for the inferences.

Parameters:
  • name (str, optional) – Name of the model. The model is stored in the database.

  • overwrite_model (bool, optional) – If set to True, training a model with the same name as an existing model overwrites the existing model.

  • **kwargs (scikit-learn model parameters.)

Variables:
  • created (Many attributes are)

  • phase. (during the fitting)

  • coef_ (numpy.array) – The regression coefficients. The order of coefficients is the same as the order of columns used during the fitting phase.

  • intercept_ (float) – The expected value of the dependent variable when all independent variables are zero, serving as the baseline or constant term in the model.

  • feature_importances_ (numpy.array) – The importance of features is computed through the model coefficients, which are normalized based on their range. Subsequently, an activation function calculates the final score. It is necessary to use the features_importance() method to compute it initially, and the computed values will be subsequently utilized for subsequent calls.

  • note:: (..) – All attributes can be accessed using the get_attributes() method.

Examples

The following examples provide a basic understanding of usage. For more detailed examples, please refer to the Machine Learning or the Examples section on the website.

Load data for machine learning

We import vastorbit:

import vastorbit as vo

Hint

By assigning an alias to vastorbit, we mitigate the risk of code collisions with other libraries. This precaution is necessary because vastorbit uses commonly known function names like “average” and “median”, which can potentially lead to naming conflicts. The use of an alias ensures that the functions from vastorbit are used as intended without interfering with functions from other libraries.

For this example, we will use the winequality dataset.

import vastorbit.datasets as vod

data = vod.load_winequality()
123
fixed_acidity
Decimal(6, 3)
123
volatile_acidity
Decimal(7, 4)
123
citric_acid
Decimal(6, 3)
123
residual_sugar
Decimal(7, 3)
123
chlorides
Double
123
free_sulfur_dioxide
Decimal(7, 2)
123
total_sulfur_dioxide
Decimal(7, 2)
123
density
Double
123
ph
Decimal(6, 3)
123
sulphates
Decimal(6, 3)
123
alcohol
Double
123
quality
Integer
123
good
Integer
Abc
color
Varchar(20)
16.30.670.4812.60.05257.0222.00.99793.170.529.360white
27.40.40.295.40.04431.0122.00.9943.30.511.181white
37.10.260.312.20.04429.0128.00.99373.340.6410.981white
49.00.310.486.60.04311.073.00.99382.90.3811.650white
56.30.390.246.90.0699.0117.00.99423.150.3510.240white
68.20.220.366.80.03412.090.00.99443.010.3810.581white
77.10.190.283.60.03316.078.00.9932.910.7811.460white
87.30.250.3613.10.0535.0200.00.99863.040.468.971white
97.90.20.341.20.0429.0118.00.99323.140.4110.660white
107.10.260.325.90.03739.097.00.99343.310.411.660white
117.00.20.345.70.03532.083.00.99283.190.4611.560white
126.90.30.334.10.03526.0155.00.99253.250.7912.381white
138.10.290.497.10.04222.0124.00.99443.140.4110.860white
145.80.170.31.40.03755.0130.00.99093.290.3811.360white
155.90.4150.020.80.03822.063.00.99323.360.369.350white
166.60.230.261.30.04516.0128.00.99343.360.610.060white
178.60.550.3515.550.05735.5366.51.00013.040.6311.030white
186.90.350.741.00.04418.0132.00.9923.130.5510.250white
197.60.140.741.60.0427.0103.00.99163.070.410.871white
209.20.280.4911.80.04229.0137.00.9983.10.3410.140white
216.20.180.494.50.04717.090.00.99193.270.3711.660white
225.30.1650.241.10.05125.0105.00.99253.320.479.150white
239.80.250.7410.00.05636.0225.00.99773.060.4310.040white
248.10.290.497.10.04222.0124.00.99443.140.4110.860white
256.80.220.490.90.05226.0128.00.9913.250.3511.460white
267.20.220.491.00.04534.0140.00.993.050.3412.760white
277.40.250.491.10.04235.0156.00.99173.130.5511.350white
288.20.180.491.10.03328.081.00.99233.00.6810.471white
296.10.220.491.50.05118.087.00.99283.30.469.650white
307.00.390.241.00.0488.0119.00.99233.00.3110.140white
316.10.220.491.50.05118.087.00.99283.30.469.650white
326.50.360.492.90.0316.094.00.99023.10.4912.171white
337.10.290.491.20.03132.099.00.98933.070.3312.260white
347.40.250.491.10.04235.0156.00.99173.130.5511.350white
356.90.230.2414.20.05319.094.00.99823.170.59.650white
368.50.560.7417.850.05151.0243.01.00052.990.79.250white
378.20.180.491.10.03328.081.00.99233.00.6810.471white
386.30.230.497.10.0567.0210.00.99513.230.349.550white
396.10.250.497.60.05267.0226.00.99563.160.478.950white
407.20.260.7413.60.0556.0162.00.9983.030.448.850white
417.20.310.241.40.05717.0117.00.99283.160.3510.550white
428.00.250.491.20.06127.0117.00.99383.080.349.450white
437.00.180.495.30.0434.0125.00.99143.240.412.260white
447.80.430.4913.00.03337.0158.00.99553.140.3511.360white
458.30.20.744.450.04433.0130.00.99243.250.4212.260white
466.30.270.491.20.06335.092.00.99113.380.4212.260white
477.40.160.491.20.05518.0150.00.99173.230.4711.260white
487.40.160.491.20.05518.0150.00.99173.230.4711.260white
496.90.190.496.60.03649.0172.00.99323.20.2711.560white
507.80.430.4913.00.03337.0158.00.99553.140.3511.360white
517.20.40.491.10.04811.0138.00.99293.010.429.350white
527.80.430.4913.00.03337.0158.00.99553.140.3511.360white
537.60.520.4914.00.03437.0156.00.99583.140.3811.871white
548.30.210.4919.80.05450.0231.01.00122.990.549.250white
556.90.340.7411.20.06944.0150.00.99683.00.819.250white
566.30.270.491.20.06335.092.00.99113.380.4212.260white
578.30.20.744.450.04433.0130.00.99243.250.4212.260white
587.10.220.742.70.04442.0144.00.9913.310.4112.260white
597.90.110.494.50.04827.0133.00.99463.240.4210.660white
608.50.170.743.60.0529.0128.00.99283.280.412.460white
616.40.1450.495.40.04854.0164.00.99463.560.4410.860white
627.40.160.491.20.05518.0150.00.99173.230.4711.260white
638.30.190.491.20.05111.0137.00.99183.060.4611.060white
648.00.440.499.10.03146.0151.00.99263.160.2712.781white
657.00.20.740.80.04419.0163.00.99313.460.5310.250white
666.90.190.496.60.03649.0172.00.99323.20.2711.560white
677.10.250.493.00.0330.096.00.99033.130.3912.371white
686.50.240.241.60.04615.060.00.99283.190.399.850white
697.20.40.491.10.04811.0138.00.99293.010.429.350white
707.60.520.4914.00.03437.0156.00.99583.140.3811.871white
717.80.430.4913.00.03337.0158.00.99553.140.3511.360white
727.80.210.491.350.0526.048.00.99113.150.2811.450white
737.00.20.495.90.03839.0128.00.99383.210.4810.860white
746.90.250.243.60.05713.085.00.99422.990.489.540white
757.20.080.491.30.0518.0148.00.99453.460.4410.260white
767.10.850.498.70.02840.0184.00.99623.220.3610.750white
777.60.510.241.20.0410.0104.00.9923.050.2910.860white
787.90.220.244.60.04439.0159.00.99272.990.2811.560white
797.70.160.492.00.05620.0124.00.99483.320.4910.760white
807.20.080.491.30.0518.0148.00.99453.460.4410.260white
816.60.250.241.70.04826.0124.00.99423.370.610.160white
826.70.160.492.40.04657.0187.00.99523.620.8110.460white
836.90.250.243.60.05713.085.00.99422.990.489.540white
847.50.320.244.60.0538.0134.00.99583.140.59.130white
857.40.280.491.50.03420.0126.00.99182.980.3910.660white
866.20.150.490.90.03317.051.00.99323.30.79.460white
876.70.250.7419.40.05444.0169.01.00043.510.459.860white
886.50.260.7413.30.04468.0224.00.99723.180.549.560white
897.90.160.7417.850.03752.0187.00.99982.990.419.350white
905.60.1850.491.10.0328.0117.00.99183.550.4510.360white
917.50.20.491.30.0318.097.00.99183.060.6211.150white
928.00.30.499.40.04647.0188.00.99643.140.4810.050white
938.00.340.499.00.03339.0180.00.99363.130.3812.381white
947.70.350.498.650.03342.0186.00.99313.140.3812.481white
957.60.290.499.60.0345.0197.00.99383.130.3812.371white
966.70.620.241.10.0396.062.00.99343.410.3210.450white
976.80.270.491.20.04435.0126.00.993.130.4812.171white
987.70.270.491.80.04123.086.00.99143.160.4212.560white
996.70.510.242.10.04314.0155.00.99043.220.613.060white
1007.40.190.499.30.0326.0132.00.9942.990.3211.071white
Rows: 1-100 | Columns: 14

Note

vastorbit offers a wide range of sample datasets that are ideal for training and testing purposes. You can explore the full list of available datasets in the Datasets, which provides detailed information on each dataset and how to use them effectively. These datasets are invaluable resources for honing your data analysis and machine learning skills within the vastorbit environment.

You can easily divide your dataset into training and testing subsets using the VastFrame.train_test_split() method. This is a crucial step when preparing your data for machine learning, as it allows you to evaluate the performance of your models accurately.

data = vod.load_winequality()
train, test = data.train_test_split(test_size = 0.2)

Warning

In this case, vastorbit utilizes seeded randomization to guarantee the reproducibility of your data split. However, please be aware that this approach may lead to reduced performance. For a more efficient data split, you can use the VastFrame.to_db() method to save your results into tables or temporary tables. This will help enhance the overall performance of the process.

Model Initialization

First we import the Ridge model:

from vastorbit.machine_learning.vast import Ridge

Then we can create the model:

model = Ridge(
    tol = 1e-6,
    alpha = 0.5,
    max_iter = 100,
    solver = 'cholesky',
)

Important

The model name is crucial for the model management system and versioning. It’s highly recommended to provide a name if you plan to reuse the model later.

Model Training

We can now fit the model:

model.fit(
    train,
    [
        "fixed_acidity",
        "volatile_acidity",
        "citric_acid",
        "residual_sugar",
        "chlorides",
        "density",
    ],
    "quality",
    test,
)

Important

To train a model, you can directly use the VastFrame or the name of the relation stored in the database. The test set is optional and is only used to compute the test metrics. In vastorbit, we don’t work using X matrices and y vectors. Instead, we work directly with lists of predictors and the response name.

Features Importance

We can conveniently get the features importance:

result = model.features_importance()

Note

For LinearModel, feature importance is computed using the coefficients. These coefficients are then normalized using the feature distribution. An activation function is applied to get the final score.

Metrics

We can get the entire report using:

model.report()
value
explained_variance0.09853742657372833
max_error2.787660357774259
median_absolute_error0.5982438991489742
mean_absolute_error0.6427562812466034
mean_squared_error73.28304611353323
root_mean_squared_error0.8292957156719737
r20.09253555929188284
r2_adj0.08828514036584945
aic5545.260184986937
bic5581.222043833587
Rows: 1-10 | Columns: 2

Important

Most metrics are computed using a single SQL query, but some of them might require multiple SQL queries. Selecting only the necessary metrics in the report can help optimize performance. E.g. model.report(metrics = ["mse", "r2"]).

For LinearModel, we can easily get the ANOVA table using:

model.report(metrics = "anova")
DfSSMSFp_value
Regression678.5025532808017913.0837588801336310.177547011714639960.9829655225407988
Residual128194399.1958163111173.69180001273311
Total12871074.583850931679
Rows: 1-3 | Columns: 6

You can also use the LinearModel.score function to compute the R-squared value:

model.score()

Prediction

Prediction is straight-forward:

model.predict(
    test,
    [
        "fixed_acidity",
        "volatile_acidity",
        "citric_acid",
        "residual_sugar",
        "chlorides",
        "density",
    ],
    "prediction",
)
123
fixed_acidity
Decimal(6, 3)
123
volatile_acidity
Decimal(7, 4)
123
citric_acid
Decimal(6, 3)
123
residual_sugar
Decimal(7, 3)
123
chlorides
Double
123
free_sulfur_dioxide
Decimal(7, 2)
123
total_sulfur_dioxide
Decimal(7, 2)
123
density
Double
123
ph
Decimal(6, 3)
123
sulphates
Decimal(6, 3)
123
alcohol
Double
123
quality
Integer
123
good
Integer
Abc
color
Varchar(20)
123
seedrand
Decimal(26, 6)
123
prediction
Double
18.80.270.255.00.02452.099.00.99252.870.4911.450white0.165.969065989519746
25.60.320.337.40.03725.095.00.992683.250.4911.160white0.185.869497132644156
36.20.230.350.70.05124.0111.00.99163.370.4311.030white0.16.0546598056992345
46.80.240.299.50.04256.0157.00.995863.110.5110.160white0.115.889013809440309
57.10.170.414.550.04747.0156.00.999453.340.789.160white0.175.869709495051355
66.40.320.274.90.03418.0122.00.99163.360.7112.560white0.075.910452804536682
78.20.340.295.20.07619.092.00.991382.950.3912.560white0.195.756630016284401
86.90.240.237.10.04120.097.00.992463.10.8511.460white0.065.937257349367567
96.00.160.221.60.04236.0106.00.99053.240.3211.460white0.06.137378096606
105.80.320.22.60.02717.0123.00.989363.360.7813.971white0.065.973684685542979
116.60.240.2710.30.04754.0219.00.997423.040.458.850white0.165.855663573907519
126.60.160.361.10.03127.093.00.988843.230.3413.281white0.136.192519115360003
136.80.190.49.850.05541.0103.00.995322.980.5610.560white0.075.922305634976469
145.90.320.284.70.03934.094.00.989643.220.5713.171white0.195.912968398449511
158.00.20.441.00.05724.0111.00.991583.090.3211.260white0.086.064277434568909
166.70.240.368.40.04242.0123.00.994733.340.5210.960white0.175.920848487282326
176.10.330.33.00.03630.0124.00.989223.310.413.171white0.165.940308443690418
186.70.240.368.40.04242.0123.00.994733.340.5210.960white0.125.920848487282326
196.90.330.314.20.0421.093.00.98963.180.4813.471white0.055.902033899769618
207.10.360.282.40.03635.0115.00.989363.190.4413.571white0.045.903542091648358
216.80.190.331.30.03122.087.00.989873.080.6212.371white0.166.144506874497989
225.90.230.243.80.03861.0152.00.991393.310.511.371white0.166.0271557718630735
236.40.280.447.10.04849.0179.00.995283.150.489.250white0.095.889182518360972
247.20.270.311.20.03127.080.00.988923.030.3312.760white0.196.0487597383182035
258.10.260.274.30.0343.0123.00.992123.160.3311.260white0.125.986476156456159
266.60.230.378.50.03646.0153.00.995763.20.489.460white0.015.945409711375209
278.10.20.280.90.02349.087.00.990622.920.3611.160white0.126.141352813227952
286.60.640.284.40.03219.078.00.990363.110.6212.960white0.045.547576801641213
297.00.480.124.50.0523.086.00.993982.860.359.050white0.055.652936644865338
307.30.230.272.60.03539.0120.00.991383.040.5911.371white0.136.0473036990486655
317.40.250.287.250.02814.078.00.992382.940.3711.571white0.135.959485164425461
327.40.250.287.250.02814.078.00.992382.940.3711.571white0.075.959485164425461
335.80.280.284.20.04452.0158.00.9923.350.4410.771white0.025.947992407736924
346.80.190.7117.50.04221.0114.00.997842.850.59.560white0.05.85310149236515
356.60.190.351.50.03737.0107.00.990063.180.6812.071white0.166.128314313416718
367.00.290.330.90.04120.0117.00.990483.210.511.450white0.016.001622279957975
376.30.20.264.70.04108.0168.00.992783.070.7510.771white0.186.035969416964183
386.50.210.5117.60.04534.0125.00.999663.20.478.860white0.175.792401761461086
396.40.240.232.00.04630.0133.00.99083.120.5411.471white0.066.021288934790709
406.40.290.243.20.03731.095.00.989422.90.6612.671white0.195.971589261391889
416.30.320.1717.750.0651.0190.00.999163.130.488.860white0.175.582950863003239
426.80.520.265.70.03827.0130.00.993.110.2713.071white0.165.649324260494895
436.10.350.071.40.06922.0108.00.99343.230.529.250white0.025.813607603272651
446.30.140.391.20.04426.0116.00.9923.260.5310.360white0.116.174296350244182
458.20.280.421.80.03130.093.00.99173.090.3911.450white0.036.020730067401803
467.20.250.3918.950.03842.0155.00.99992.970.479.060white0.045.719824904389421
477.40.310.281.60.0533.0137.00.99293.310.5610.560white0.075.923765305826235
487.00.210.288.70.04537.0222.00.99543.250.5410.460white0.085.929142638935156
497.00.210.288.60.04537.0221.00.99543.250.5410.460white0.155.930851989079272
507.00.210.288.70.04537.0222.00.99543.250.5410.460white0.195.929142638935156
516.80.290.513.30.05348.0194.00.99743.090.459.450white0.065.753735786989681
526.60.520.4412.20.04854.0245.00.99753.260.549.360white0.025.50670928640562
537.10.210.278.60.05626.0111.00.99562.950.529.550white0.145.898607844630894
547.20.390.6211.00.04766.0178.00.99763.160.58.750white0.175.6999032063682975
557.00.140.329.00.03954.0141.00.99563.220.439.460white0.196.027294671543225
565.50.160.224.50.0330.0102.00.99383.240.369.460white0.116.1123023277718485
576.70.470.348.90.04331.0172.00.99643.220.69.250white0.045.627604727814193
586.20.370.36.60.34679.0200.00.99543.290.589.650white0.134.976202418533086
597.40.260.317.60.04752.0177.00.99623.130.458.960white0.075.880252529656076
605.70.440.137.00.02528.0173.00.99133.330.4812.560white0.115.7467995053809755
617.20.280.5416.70.04554.0200.00.9993.080.499.560white0.025.724399562064983
626.80.190.5814.20.03851.0164.00.99753.120.489.660white0.115.906455978084731
637.80.180.3112.20.05346.0140.00.9983.060.538.960white0.075.87078197366891
645.90.620.283.50.03955.0152.00.99073.440.4412.060white0.015.572701498917045
657.40.150.421.70.04549.0154.00.9923.00.610.460white0.086.14527233599026
665.90.130.281.90.0520.078.00.99183.430.6410.860white0.116.1495521844248024
677.90.190.262.10.0398.0143.00.99423.050.749.850white0.046.076231235992088
685.60.190.474.50.0319.0112.00.99223.560.4511.260white0.16.11043513524874
697.90.3450.5115.30.04754.0171.00.99873.090.519.150white0.155.65729134662698
706.70.310.319.90.0410.0175.00.99533.460.5511.440white0.075.809447268347852
717.20.460.6510.40.0576.0192.00.99763.160.428.750white0.155.622290272020756
727.70.220.421.90.05210.087.00.99223.30.4911.860white0.176.036508943141876
737.20.460.6510.40.0576.0192.00.99763.160.428.750white0.065.622290272020756
747.00.30.5113.60.0540.0168.00.99763.070.529.671white0.095.743487266810968
759.20.250.341.20.02631.093.00.99162.930.3711.371white0.036.062704688923436
768.40.350.7112.20.04622.0160.00.99822.980.659.450white0.075.727675970504558
776.10.410.241.60.04916.0137.00.9933.320.510.460white0.065.813549719736441
785.90.370.11.60.05739.0128.00.99243.240.4810.150white0.115.827380202846137
796.00.260.52.20.04859.0153.00.99283.080.619.850white0.16.016057651947962
807.20.20.342.70.03249.0151.00.993.160.3912.771white0.096.103274868734337
818.20.220.31.80.04747.0185.00.99333.130.510.260white0.076.02952973941054
828.20.230.291.80.04747.0187.00.99333.130.510.260white0.096.016476555241702
836.50.280.292.70.03826.0107.00.99123.320.4111.671white0.135.987826866279626
845.70.180.224.20.04225.0111.00.9943.350.399.450white0.116.059011450272631
857.40.260.37.90.04938.0157.00.99633.130.488.960white0.185.868240900252858
866.10.320.251.70.03437.0136.00.9923.470.510.871white0.075.963945569690523
876.90.280.272.10.03642.0121.00.99263.420.4910.871white0.035.992661822073934
886.40.450.071.10.0310.0131.00.99052.970.2810.850white0.075.812347599886957
897.00.290.374.90.03426.0127.00.99283.170.4410.860white0.035.94824469742974
906.70.30.351.40.1836.0160.00.99373.110.549.460white0.125.6014353348413195
916.40.450.071.10.0310.0131.00.99052.970.2810.850white0.165.812347599886957
927.30.250.297.50.04938.0158.00.99653.430.389.650white0.075.885947489637097
937.30.250.297.50.04938.0158.00.99653.430.389.650white0.155.885947489637097
946.50.360.283.20.03729.0119.00.99083.250.6512.481white0.085.887073522849356
957.80.260.271.90.05152.0195.00.99283.230.510.960white0.155.971246726226131
967.00.320.246.20.04831.0228.00.99573.230.629.460white0.15.8272419933444635
975.80.310.331.20.03623.099.00.99163.180.610.560white0.145.992268598946566
987.00.230.4218.050.0535.0144.00.99993.220.428.850white0.05.731976614707593
997.00.230.4218.050.0535.0144.00.99993.220.428.850white0.125.731976614707593
1005.80.3350.145.80.04649.0197.00.99373.30.7110.350white0.195.827505497022953
Rows: 1-100 | Columns: 16

Note

Predictions can be made automatically using the test set, in which case you don’t need to specify the predictors. Alternatively, you can pass only the VastFrame to the predict() function, but in this case, it’s essential that the column names of the VastFrame match the predictors and response name in the model.

Plots

If the model allows, you can also generate relevant plots. For example, regression plots can be found in the Machine Learning - Regression Plots.

model.plot()

Important

The plotting feature is typically suitable for models with fewer than three predictors.

Contour plot is another useful plot that can be produced for models with two predictors.

model.contour()

Important

Machine learning models with two predictors can usually benefit from their own contour plot. This visual representation aids in exploring predictions and gaining a deeper understanding of how these models perform in different scenarios. Please refer to Contour Plot for more examples.

Parameter Modification

In order to see the parameters:

model.get_params()

And to manually change some of the parameters:

model.set_params({'tol': 0.001})

Model Exporting

To Memmodel

model.to_memmodel()

Note

MemModel objects serve as in-memory representations of machine learning models. They can be used for both in-database and in-memory prediction tasks. These objects can be pickled in the same way that you would pickle a scikit-learn model.

The following methods for exporting the model use MemModel, and it is recommended to use MemModel directly.

To SQL

You can get the SQL code by:

model.to_sql()

To Python

To obtain the prediction function in Python syntax, use the following code:

X = [[4.2, 0.17, 0.36, 1.8, 0.029, 0.9899]]
model.to_python()(X)

Hint

The to_python() method is used to retrieve predictions, probabilities, or cluster distances. For specific details on how to use this method for different model types, refer to the relevant documentation for each model.

__init__(name: str = None, overwrite_model: bool = False, **kwargs) None

Methods

__init__([name, overwrite_model])

contour([nbins, chart])

Draws the model's contour plot.

deploySQL([X])

Returns the SQL code needed to deploy the model.

drop()

Drops the model from the VAST DataBase.

export_models(name, path[, kind])

Exports machine learning models.

features_importance([show, chart])

Computes the model's features importance.

fit(input_relation, X, y[, test_relation, ...])

Trains the model.

get_attributes([attr_name])

Returns the model attributes.

get_match_index(x, col_list[, str_check])

Returns the matching index.

get_params()

Returns the parameters of the model.

get_plotting_lib([class_name, chart, ...])

Returns the first available library (Plotly, Matplotlib) to draw a specific graphic.

import_models(path[, schema, kind])

Imports machine learning models.

plot([max_nb_points, chart])

Draws the model.

predict(vdf[, X, name, inplace])

Predicts using the input relation.

regression_report([metrics])

Computes a regression report using multiple metrics to evaluate the model (r2, mse, max error...).

report([metrics])

Computes a regression report using multiple metrics to evaluate the model (r2, mse, max error...).

score([metric])

Computes the model score.

set_params([parameters])

Sets the parameters of the model.

summarize()

Summarizes the model.

to_binary(path)

Exports the model to the VAST Binary format.

to_memmodel()

Converts the model to an InMemory object that can be used for different types of predictions.

to_python([return_proba, ...])

Returns the Python function needed for in-memory scoring without using built-in VAST functions.

to_sql([X, return_proba, ...])

Returns the SQL code needed to deploy the model without using built-in VAST functions.

Attributes