# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     name: python3
# ---

# + [markdown] id="view-in-github" colab_type="text"
# <a href="https://colab.research.google.com/github/lfr4704/lambdata-dspt5/blob/master/my_python_module.ipynb" target="_parent"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"/></a>

# + id="TNUKcdpHEvRD" colab_type="code" outputId="37b474a1-73e3-4203-b220-1a561adf4587" colab={"base_uri": "https://localhost:8080/", "height": 122}
# !pip install -i https://test.pypi.org/simple/ lfr-lambdata-pt5

# + id="7Y-bxkYTFXcE" colab_type="code" outputId="6629eff2-da8a-4836-e425-b6c4196f61c9" colab={"base_uri": "https://localhost:8080/", "height": 34}
from my_lambdata.my_mod import enlarge #import method from module 

x = 11
print(enlarge(x))

# + [markdown] id="lD8RAvBdEh8U" colab_type="text"
# #Test State Abbreviation function

# + id="WEJfE8zSEwde" colab_type="code" colab={"base_uri": "https://localhost:8080/", "height": 204} outputId="a3334b30-c06d-4a5a-9c6d-eb2760014799"
import pandas as pd
from my_lambdata.assignment import add_state_name # import method from module
import numpy as np

abbrev_df = pd.DataFrame({"abbrev": ["CA", "CO", "CT", "WA", "TX"]})

abbrev_df2=add_state_name(abbrev_df)

abbrev_df2.head()

# + [markdown] id="bxe8KmbQEwxU" colab_type="text"
# #Test timestamp abbreviation function 

# + id="lsG3R-2EE6jI" colab_type="code" colab={"base_uri": "https://localhost:8080/", "height": 142} outputId="9c632360-2886-42a4-dec2-13add1024736"
from my_lambdata.assignment import split_timestamp #import method from module

df3 = pd.DataFrame({"timestamp":["2010-01-04", "2012-05-04", "2008-11-02"]})

df_timestamp_split = split_timestamp(df3)

df_timestamp_split.head()

StarcoderdataJupyterScriptsDedupFiltered