Teradata Package for Python Function Reference on VantageCloud Lake - archive_feature - Teradata Package for Python - Look here for syntax, methods and examples for the functions included in the Teradata Package for Python.
Teradata® Package for Python Function Reference on VantageCloud Lake
- Deployment
- VantageCloud
- Edition
- Lake
- Product
- Teradata Package for Python
- Release Number
- 20.00.00.03
- Published
- December 2024
- ft:locale
- en-US
- ft:lastEdition
- 2024-12-19
- dita:id
- TeradataPython_FxRef_Lake_2000
- Product Category
- Teradata Vantage
- teradataml.store.feature_store.feature_store.FeatureStore.archive_feature = archive_feature(self, feature)
- DESCRIPTION:
Archives Feature from repository. Note that archived Feature
is not available for any further processing. Archived Feature can be
viewed using "list_archived_features()" method.
PARAMETERS:
feature:
Required Argument.
Specifies either the name of Feature or Object of Feature
to archive from repository.
Types: str OR Feature
RETURNS:
bool
RAISES:
TeradataMLException, TypeError, ValueError
EXAMPLES:
>>> from teradataml import DataFrame, Feature, FeatureStore
>>> load_example_data('dataframe', ['sales'])
# Create teradataml DataFrame.
>>> df = DataFrame("sales")
# Create Feature for Column 'Feb'.
>>> feature = Feature(name="sales_data_Feb", column=df.Feb)
# Create FeatureStore for the repo 'staging_repo'.
>>> fs = FeatureStore("staging_repo")
# Apply the Feature to FeatureStore.
>>> fs.apply(feature)
True
# List the available Features.
>>> fs.list_features()
column_name description creation_time modified_time tags data_type feature_type status group_name
name
sales_data_Feb Feb None 2024-10-03 18:21:03.720464 None None FLOAT CONTINUOUS ACTIVE None
# Archive Feature with name "sales_data_Feb".
>>> fs.archive_feature(feature=feature)
Feature 'sales_data_Feb' is archived.
True
# List the available Features after archive.
>>> fs.list_features()
Empty DataFrame
Columns: [column_name, description, creation_time, modified_time, tags, data_type, feature_type, status, group_name]
Index: []
>>>