def get_data(**kwargs):
    '''
      Args
      -------
      filepath

      Returns
      -------
        Data : bnpy XData object, with nObsTotal observations
    '''
    X = np.loadtxt(filepath, dtype=np.float64)
    Data = XData(X=X)
    Data.name = get_short_name()
    Data.summary = get_data_info()
    return Data
Ejemplo n.º 2
0
def get_data(seed=8675309, nObsTotal=25000, **kwargs):
    '''
      Args
      -------
      seed : integer seed for random number generator,
              used for actually *generating* the data
      nObsTotal : total number of observations for the dataset.

      Returns
      -------
      Data : bnpy XData object, with nObsTotal observations
    '''
    X, TrueZ = get_X(seed, nObsTotal)
    Data = XData(X=X, TrueZ=TrueZ)
    Data.name = 'AsteriskK8'
    Data.summary = get_data_info()
    return Data
def get_data(seed=8675309, nObsTotal=25000, **kwargs):
    ''' Create and return toy dataset from 1D standard normal distribution.

    Args
    -------
    seed : integer seed for random number generator,
        used for actually *generating* the data
    nObsTotal : total number of observations for the dataset.

    Returns
    -------
    Data : bnpy XData object, with nObsTotal observations
    '''
    X, TrueZ = generate_data(seed, nObsTotal)
    Data = XData(X=X, TrueZ=TrueZ)
    Data.name = get_short_name()
    Data.summary = get_data_info()
    return Data
Ejemplo n.º 4
0
def get_data(seed=8675309, nObsTotal=None, nPerState=20, **kwargs):
    '''
      Args
      -------
      seed : integer seed for random number generator,
              used for actually *generating* the data
      nObsTotal : total number of observations for the dataset.

      Returns
      -------
        Data : bnpy XData object, with nObsTotal observations
    '''
    if nObsTotal is not None:
        nPerState = nObsTotal // K
    X, TrueZ = genToyData(seed=seed, nPerState=nPerState)
    Data = XData(X=X, TrueZ=TrueZ)
    Data.name = get_short_name()
    Data.summary = get_data_info()
    return Data
Ejemplo n.º 5
0
def get_data(seed=8675309, nObsTotal=25000, **kwargs):
    X, TrueZ = generateData(seed, nObsTotal)
    Data = XData(X=X, TrueZ=TrueZ)
    Data.name = get_short_name()
    Data.summary = get_data_info()
    return Data