interval¶
In [ ]:
interval(expr)
Converts the input value to a INTERVAL data type.
Parameters¶
| Name | Type | Optional | Description |
|---|---|---|---|
expr | object | ❌ | Expression. |
In [85]:
from verticapy import *
df = tablesample({"x": ['1 day', '2 hours']}).to_vdf()
display(df)
In [86]:
# Importing the stats module
import verticapy.stats as st
# Applying the interval function
df["interval_x"] = st.interval(df["x"])
display(df)
