code: def get_treasury_yield(start=None, end=None, period="3MO"):
      """
      Load treasury yields from FRED.
  
      Parameters
      ----------
      start : date, optional
          Earliest date to fetch data for.
          Defaults to earliest date available.
      end : date, optional
          Latest date to fetch data for.
          Defaults to latest date available.
      period : {'1MO', '3MO', '6MO', 1', '5', '10'}, optional
          Which maturity to use.
      Returns
      -------
      pd.Series
          Annual treasury yield for every day.
      """
  
      if start is None:
          start = "1/1/1970"
      if end is None:
          end = _1_bday_ago()
  
      treasury = web.DataReader(
          "DGS3{}".format(period), "fred", start, end
      )
  
      treasury = treasury.ffill()
  
      return treasury
  
imports: from datetime import datetime
  from functools import wraps
  from os import makedirs, environ
  from os.path import expanduser, join, getmtime, isdir
  import errno
  import warnings
  import numpy
  from numpy.lib.stride_tricks import as_strided
  import pandas
  from pandas.tseries.offsets import BDay
  from .deprecate import deprecated
label_desc: Use image node_id 14 for calling a global function with example usage: get_treasury_yield(start, end, period) and returns: treasury