Port a trained estimator to the syntax of a chosen programming
        language.

        Parameters
        ----------
        :param class_name : string
            The name of the class in the returned result.
        :param method_name: string
            The name of the method in the returned result.
        :param export_data : bool
            Whether the model data should be saved or not.
        :param export_dir : string
            The directory where the model data should be saved.
        :param export_filename : string
            The filename of the exported model data.
        :param export_append_checksum : bool
            Whether to append the checksum to the filename or not.
        :param embed_data : bool, default: True
            Whether the model data should be embedded in the template or not.

        Returns
        -------
        :return : string
            The transpiled algorithm with the defined placeholders.

def export(self, class_name, method_name,
               export_data=False, export_dir='.', export_filename='data.json',
               export_append_checksum=False, embed_data=True, **kwargs):
        """
        Port a trained estimator to the syntax of a chosen programming
        language.

        Parameters
        ----------
        :param class_name : string
            The name of the class in the returned result.
        :param method_name: string
            The name of the method in the returned result.
        :param export_data : bool
            Whether the model data should be saved or not.
        :param export_dir : string
            The directory where the model data should be saved.
        :param export_filename : string
            The filename of the exported model data.
        :param export_append_checksum : bool
            Whether to append the checksum to the filename or not.
        :param embed_data : bool, default: True
            Whether the model data should be embedded in the template or not.

        Returns
        -------
        :return : string
            The transpiled algorithm with the defined placeholders.
        """
        # Arguments:
        self.class_name = class_name
        self.method_name = method_name

        # Estimator:
        est = self.estimator

        # Basic parameters:
        self.estimators = []
        for idx in range(est.n_estimators):
            if est.estimator_weights_[idx] > 0:
                self.estimators.append(est.estimators_[idx])
        self.n_classes = est.n_classes_
        self.n_features = est.estimators_[0].n_features_
        self.n_estimators = len(self.estimator)

        if self.target_method == 'predict':
            # Exported:
            if export_data and os.path.isdir(export_dir):
                self.export_data(export_dir, export_filename,
                                 export_append_checksum)
                return self.predict('exported')
            # Embedded:
            return self.predict('embedded')