def extract_dmhq(df):
    """
    Extract day of week, day of month, month, minute, hour, day of year of given DataFrame with time stamp.
    
    Parameters
    ----------
    df: pd.DataFrame with timestamp as index.

    Returns
    -------
    df: pd.DataFrame
        The new dataframe with new time-oriented features.

    """
    df['date'] = df.index.astype('datetime64[ns]')
    df['wd'] = df['date'].dt.dayofweek 
    df['month'] = df['date'].dt.month
    df['day'] = df['date'].dt.day
    df['hour'] = df['date'].dt.hour
    df['minute'] = df['date'].dt.minute
    df['yd'] = df['date'].dt.dayofyear
    df.drop(['date'], axis = 1, inplace = True)
    return df