1. Packages
  2. DataRobot
  3. API Docs
  4. CustomMetric
DataRobot v0.9.0 published on Tuesday, Apr 8, 2025 by DataRobot, Inc.

datarobot.CustomMetric

Explore with Pulumi AI

Custom Metric

Example Usage

Coming soon!
Coming soon!
Coming soon!
Coming soon!
Coming soon!
resources:
  example:
    type: datarobot:CustomMetric
    properties:
      deploymentId: ${datarobot_deployment.example.id}
      description: example description
      units: dollars
      directionality: higherIsBetter
      type: sum
      baselineValue: 0.5
      isModelSpecific: true
      isGeospatial: false
      # Optional
      timeStep: hour
      timestamp:
        column_name: timestamp_column
        time_format: '%Y-%m-%dT%H:%M:%SZ'
      value:
        column_name: value_column
      batch:
        column_name: batch_column
      sampleCount:
        column_name: sample_count_column
      associationId:
        columnName: association_id_column
outputs:
  exampleId: ${example.id}
Copy

Create CustomMetric Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new CustomMetric(name: string, args: CustomMetricArgs, opts?: CustomResourceOptions);
@overload
def CustomMetric(resource_name: str,
                 args: CustomMetricArgs,
                 opts: Optional[ResourceOptions] = None)

@overload
def CustomMetric(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 is_model_specific: Optional[bool] = None,
                 units: Optional[str] = None,
                 deployment_id: Optional[str] = None,
                 type: Optional[str] = None,
                 directionality: Optional[str] = None,
                 is_geospatial: Optional[bool] = None,
                 description: Optional[str] = None,
                 name: Optional[str] = None,
                 sample_count: Optional[CustomMetricSampleCountArgs] = None,
                 timestamp: Optional[CustomMetricTimestampArgs] = None,
                 baseline_value: Optional[float] = None,
                 batch: Optional[CustomMetricBatchArgs] = None,
                 value: Optional[CustomMetricValueArgs] = None)
func NewCustomMetric(ctx *Context, name string, args CustomMetricArgs, opts ...ResourceOption) (*CustomMetric, error)
public CustomMetric(string name, CustomMetricArgs args, CustomResourceOptions? opts = null)
public CustomMetric(String name, CustomMetricArgs args)
public CustomMetric(String name, CustomMetricArgs args, CustomResourceOptions options)
type: datarobot:CustomMetric
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. CustomMetricArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. CustomMetricArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. CustomMetricArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. CustomMetricArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. CustomMetricArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var customMetricResource = new Datarobot.CustomMetric("customMetricResource", new()
{
    IsModelSpecific = false,
    Units = "string",
    DeploymentId = "string",
    Type = "string",
    Directionality = "string",
    IsGeospatial = false,
    Description = "string",
    Name = "string",
    SampleCount = new Datarobot.Inputs.CustomMetricSampleCountArgs
    {
        ColumnName = "string",
    },
    Timestamp = new Datarobot.Inputs.CustomMetricTimestampArgs
    {
        ColumnName = "string",
        TimeFormat = "string",
    },
    BaselineValue = 0,
    Batch = new Datarobot.Inputs.CustomMetricBatchArgs
    {
        ColumnName = "string",
    },
    Value = new Datarobot.Inputs.CustomMetricValueArgs
    {
        ColumnName = "string",
    },
});
Copy
example, err := datarobot.NewCustomMetric(ctx, "customMetricResource", &datarobot.CustomMetricArgs{
	IsModelSpecific: pulumi.Bool(false),
	Units:           pulumi.String("string"),
	DeploymentId:    pulumi.String("string"),
	Type:            pulumi.String("string"),
	Directionality:  pulumi.String("string"),
	IsGeospatial:    pulumi.Bool(false),
	Description:     pulumi.String("string"),
	Name:            pulumi.String("string"),
	SampleCount: &datarobot.CustomMetricSampleCountArgs{
		ColumnName: pulumi.String("string"),
	},
	Timestamp: &datarobot.CustomMetricTimestampArgs{
		ColumnName: pulumi.String("string"),
		TimeFormat: pulumi.String("string"),
	},
	BaselineValue: pulumi.Float64(0),
	Batch: &datarobot.CustomMetricBatchArgs{
		ColumnName: pulumi.String("string"),
	},
	Value: &datarobot.CustomMetricValueArgs{
		ColumnName: pulumi.String("string"),
	},
})
Copy
var customMetricResource = new CustomMetric("customMetricResource", CustomMetricArgs.builder()
    .isModelSpecific(false)
    .units("string")
    .deploymentId("string")
    .type("string")
    .directionality("string")
    .isGeospatial(false)
    .description("string")
    .name("string")
    .sampleCount(CustomMetricSampleCountArgs.builder()
        .columnName("string")
        .build())
    .timestamp(CustomMetricTimestampArgs.builder()
        .columnName("string")
        .timeFormat("string")
        .build())
    .baselineValue(0)
    .batch(CustomMetricBatchArgs.builder()
        .columnName("string")
        .build())
    .value(CustomMetricValueArgs.builder()
        .columnName("string")
        .build())
    .build());
Copy
custom_metric_resource = datarobot.CustomMetric("customMetricResource",
    is_model_specific=False,
    units="string",
    deployment_id="string",
    type="string",
    directionality="string",
    is_geospatial=False,
    description="string",
    name="string",
    sample_count={
        "column_name": "string",
    },
    timestamp={
        "column_name": "string",
        "time_format": "string",
    },
    baseline_value=0,
    batch={
        "column_name": "string",
    },
    value={
        "column_name": "string",
    })
Copy
const customMetricResource = new datarobot.CustomMetric("customMetricResource", {
    isModelSpecific: false,
    units: "string",
    deploymentId: "string",
    type: "string",
    directionality: "string",
    isGeospatial: false,
    description: "string",
    name: "string",
    sampleCount: {
        columnName: "string",
    },
    timestamp: {
        columnName: "string",
        timeFormat: "string",
    },
    baselineValue: 0,
    batch: {
        columnName: "string",
    },
    value: {
        columnName: "string",
    },
});
Copy
type: datarobot:CustomMetric
properties:
    baselineValue: 0
    batch:
        columnName: string
    deploymentId: string
    description: string
    directionality: string
    isGeospatial: false
    isModelSpecific: false
    name: string
    sampleCount:
        columnName: string
    timestamp:
        columnName: string
        timeFormat: string
    type: string
    units: string
    value:
        columnName: string
Copy

CustomMetric Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The CustomMetric resource accepts the following input properties:

DeploymentId This property is required. string
ID of the Deployment for the Custom Metric.
Directionality This property is required. string
Directionality of the Custom Metric
IsGeospatial This property is required. bool
Determines whether the metric is geospatial.
IsModelSpecific This property is required. bool
Determines whether the metric is related to the model or deployment.
Type This property is required. string
Aggregation type of the Custom Metric.
Units This property is required. string
The units, or the y-axis label, of the given Custom Metric.
BaselineValue double
The baseline value used to add “reference dots” to the values over time chart.
Batch DataRobotCustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
Description string
Description of the Custom Metric.
Name string
Name of the Custom Metric.
SampleCount DataRobotCustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
Timestamp DataRobotCustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
Value DataRobotCustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
DeploymentId This property is required. string
ID of the Deployment for the Custom Metric.
Directionality This property is required. string
Directionality of the Custom Metric
IsGeospatial This property is required. bool
Determines whether the metric is geospatial.
IsModelSpecific This property is required. bool
Determines whether the metric is related to the model or deployment.
Type This property is required. string
Aggregation type of the Custom Metric.
Units This property is required. string
The units, or the y-axis label, of the given Custom Metric.
BaselineValue float64
The baseline value used to add “reference dots” to the values over time chart.
Batch CustomMetricBatchArgs
A Custom Metric batch ID source when reading values from columnar dataset.
Description string
Description of the Custom Metric.
Name string
Name of the Custom Metric.
SampleCount CustomMetricSampleCountArgs
A Custom Metric sample source when reading values from columnar dataset.
Timestamp CustomMetricTimestampArgs
A Custom Metric timestamp column source when reading values from columnar dataset.
Value CustomMetricValueArgs
A Custom Metric value source when reading values from columnar dataset.
deploymentId This property is required. String
ID of the Deployment for the Custom Metric.
directionality This property is required. String
Directionality of the Custom Metric
isGeospatial This property is required. Boolean
Determines whether the metric is geospatial.
isModelSpecific This property is required. Boolean
Determines whether the metric is related to the model or deployment.
type This property is required. String
Aggregation type of the Custom Metric.
units This property is required. String
The units, or the y-axis label, of the given Custom Metric.
baselineValue Double
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
description String
Description of the Custom Metric.
name String
Name of the Custom Metric.
sampleCount CustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
value CustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
deploymentId This property is required. string
ID of the Deployment for the Custom Metric.
directionality This property is required. string
Directionality of the Custom Metric
isGeospatial This property is required. boolean
Determines whether the metric is geospatial.
isModelSpecific This property is required. boolean
Determines whether the metric is related to the model or deployment.
type This property is required. string
Aggregation type of the Custom Metric.
units This property is required. string
The units, or the y-axis label, of the given Custom Metric.
baselineValue number
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
description string
Description of the Custom Metric.
name string
Name of the Custom Metric.
sampleCount CustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
value CustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
deployment_id This property is required. str
ID of the Deployment for the Custom Metric.
directionality This property is required. str
Directionality of the Custom Metric
is_geospatial This property is required. bool
Determines whether the metric is geospatial.
is_model_specific This property is required. bool
Determines whether the metric is related to the model or deployment.
type This property is required. str
Aggregation type of the Custom Metric.
units This property is required. str
The units, or the y-axis label, of the given Custom Metric.
baseline_value float
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatchArgs
A Custom Metric batch ID source when reading values from columnar dataset.
description str
Description of the Custom Metric.
name str
Name of the Custom Metric.
sample_count CustomMetricSampleCountArgs
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestampArgs
A Custom Metric timestamp column source when reading values from columnar dataset.
value CustomMetricValueArgs
A Custom Metric value source when reading values from columnar dataset.
deploymentId This property is required. String
ID of the Deployment for the Custom Metric.
directionality This property is required. String
Directionality of the Custom Metric
isGeospatial This property is required. Boolean
Determines whether the metric is geospatial.
isModelSpecific This property is required. Boolean
Determines whether the metric is related to the model or deployment.
type This property is required. String
Aggregation type of the Custom Metric.
units This property is required. String
The units, or the y-axis label, of the given Custom Metric.
baselineValue Number
The baseline value used to add “reference dots” to the values over time chart.
batch Property Map
A Custom Metric batch ID source when reading values from columnar dataset.
description String
Description of the Custom Metric.
name String
Name of the Custom Metric.
sampleCount Property Map
A Custom Metric sample source when reading values from columnar dataset.
timestamp Property Map
A Custom Metric timestamp column source when reading values from columnar dataset.
value Property Map
A Custom Metric value source when reading values from columnar dataset.

Outputs

All input properties are implicitly available as output properties. Additionally, the CustomMetric resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing CustomMetric Resource

Get an existing CustomMetric resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: CustomMetricState, opts?: CustomResourceOptions): CustomMetric
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        baseline_value: Optional[float] = None,
        batch: Optional[CustomMetricBatchArgs] = None,
        deployment_id: Optional[str] = None,
        description: Optional[str] = None,
        directionality: Optional[str] = None,
        is_geospatial: Optional[bool] = None,
        is_model_specific: Optional[bool] = None,
        name: Optional[str] = None,
        sample_count: Optional[CustomMetricSampleCountArgs] = None,
        timestamp: Optional[CustomMetricTimestampArgs] = None,
        type: Optional[str] = None,
        units: Optional[str] = None,
        value: Optional[CustomMetricValueArgs] = None) -> CustomMetric
func GetCustomMetric(ctx *Context, name string, id IDInput, state *CustomMetricState, opts ...ResourceOption) (*CustomMetric, error)
public static CustomMetric Get(string name, Input<string> id, CustomMetricState? state, CustomResourceOptions? opts = null)
public static CustomMetric get(String name, Output<String> id, CustomMetricState state, CustomResourceOptions options)
resources:  _:    type: datarobot:CustomMetric    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
BaselineValue double
The baseline value used to add “reference dots” to the values over time chart.
Batch DataRobotCustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
DeploymentId string
ID of the Deployment for the Custom Metric.
Description string
Description of the Custom Metric.
Directionality string
Directionality of the Custom Metric
IsGeospatial bool
Determines whether the metric is geospatial.
IsModelSpecific bool
Determines whether the metric is related to the model or deployment.
Name string
Name of the Custom Metric.
SampleCount DataRobotCustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
Timestamp DataRobotCustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
Type string
Aggregation type of the Custom Metric.
Units string
The units, or the y-axis label, of the given Custom Metric.
Value DataRobotCustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
BaselineValue float64
The baseline value used to add “reference dots” to the values over time chart.
Batch CustomMetricBatchArgs
A Custom Metric batch ID source when reading values from columnar dataset.
DeploymentId string
ID of the Deployment for the Custom Metric.
Description string
Description of the Custom Metric.
Directionality string
Directionality of the Custom Metric
IsGeospatial bool
Determines whether the metric is geospatial.
IsModelSpecific bool
Determines whether the metric is related to the model or deployment.
Name string
Name of the Custom Metric.
SampleCount CustomMetricSampleCountArgs
A Custom Metric sample source when reading values from columnar dataset.
Timestamp CustomMetricTimestampArgs
A Custom Metric timestamp column source when reading values from columnar dataset.
Type string
Aggregation type of the Custom Metric.
Units string
The units, or the y-axis label, of the given Custom Metric.
Value CustomMetricValueArgs
A Custom Metric value source when reading values from columnar dataset.
baselineValue Double
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
deploymentId String
ID of the Deployment for the Custom Metric.
description String
Description of the Custom Metric.
directionality String
Directionality of the Custom Metric
isGeospatial Boolean
Determines whether the metric is geospatial.
isModelSpecific Boolean
Determines whether the metric is related to the model or deployment.
name String
Name of the Custom Metric.
sampleCount CustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
type String
Aggregation type of the Custom Metric.
units String
The units, or the y-axis label, of the given Custom Metric.
value CustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
baselineValue number
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatch
A Custom Metric batch ID source when reading values from columnar dataset.
deploymentId string
ID of the Deployment for the Custom Metric.
description string
Description of the Custom Metric.
directionality string
Directionality of the Custom Metric
isGeospatial boolean
Determines whether the metric is geospatial.
isModelSpecific boolean
Determines whether the metric is related to the model or deployment.
name string
Name of the Custom Metric.
sampleCount CustomMetricSampleCount
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestamp
A Custom Metric timestamp column source when reading values from columnar dataset.
type string
Aggregation type of the Custom Metric.
units string
The units, or the y-axis label, of the given Custom Metric.
value CustomMetricValue
A Custom Metric value source when reading values from columnar dataset.
baseline_value float
The baseline value used to add “reference dots” to the values over time chart.
batch CustomMetricBatchArgs
A Custom Metric batch ID source when reading values from columnar dataset.
deployment_id str
ID of the Deployment for the Custom Metric.
description str
Description of the Custom Metric.
directionality str
Directionality of the Custom Metric
is_geospatial bool
Determines whether the metric is geospatial.
is_model_specific bool
Determines whether the metric is related to the model or deployment.
name str
Name of the Custom Metric.
sample_count CustomMetricSampleCountArgs
A Custom Metric sample source when reading values from columnar dataset.
timestamp CustomMetricTimestampArgs
A Custom Metric timestamp column source when reading values from columnar dataset.
type str
Aggregation type of the Custom Metric.
units str
The units, or the y-axis label, of the given Custom Metric.
value CustomMetricValueArgs
A Custom Metric value source when reading values from columnar dataset.
baselineValue Number
The baseline value used to add “reference dots” to the values over time chart.
batch Property Map
A Custom Metric batch ID source when reading values from columnar dataset.
deploymentId String
ID of the Deployment for the Custom Metric.
description String
Description of the Custom Metric.
directionality String
Directionality of the Custom Metric
isGeospatial Boolean
Determines whether the metric is geospatial.
isModelSpecific Boolean
Determines whether the metric is related to the model or deployment.
name String
Name of the Custom Metric.
sampleCount Property Map
A Custom Metric sample source when reading values from columnar dataset.
timestamp Property Map
A Custom Metric timestamp column source when reading values from columnar dataset.
type String
Aggregation type of the Custom Metric.
units String
The units, or the y-axis label, of the given Custom Metric.
value Property Map
A Custom Metric value source when reading values from columnar dataset.

Supporting Types

CustomMetricBatch
, CustomMetricBatchArgs

ColumnName string
Column name.
ColumnName string
Column name.
columnName String
Column name.
columnName string
Column name.
column_name str
Column name.
columnName String
Column name.

CustomMetricSampleCount
, CustomMetricSampleCountArgs

ColumnName string
Column name.
ColumnName string
Column name.
columnName String
Column name.
columnName string
Column name.
column_name str
Column name.
columnName String
Column name.

CustomMetricTimestamp
, CustomMetricTimestampArgs

ColumnName string
Column name.
TimeFormat string
Format.
ColumnName string
Column name.
TimeFormat string
Format.
columnName String
Column name.
timeFormat String
Format.
columnName string
Column name.
timeFormat string
Format.
column_name str
Column name.
time_format str
Format.
columnName String
Column name.
timeFormat String
Format.

CustomMetricValue
, CustomMetricValueArgs

ColumnName string
Column name.
ColumnName string
Column name.
columnName String
Column name.
columnName string
Column name.
column_name str
Column name.
columnName String
Column name.

Package Details

Repository
datarobot datarobot-community/pulumi-datarobot
License
Apache-2.0
Notes
This Pulumi package is based on the datarobot Terraform Provider.