Did I find the right examples for you? yes no

All Samples(10)  |  Call(10)  |  Derive(0)  |  Import(0)

src/n/i/nitime-0.4/nitime/tests/test_timeseries.py   nitime(Download)
                       sampling_rate=2 * a.sampling_rate)
 
    npt.assert_equal(ts.Frequency(b.sampling_rate),
                     ts.Frequency(2 * a.sampling_rate))
    npt.assert_equal(b.sampling_interval,
def test_Frequency():
    """Test frequency representation object"""
    tuc = ts.time_unit_conversion
    for unit in ['ns', 'ms', 's', None]:
        f = ts.Frequency(1, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit])
 
        f = ts.Frequency(1000, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit] / 1000)
 
        f = ts.Frequency(0.001, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit] * 1000)
 

src/n/i/nitime-HEAD/nitime/tests/test_timeseries.py   nitime(Download)
                       sampling_rate=2 * a.sampling_rate)
 
    npt.assert_equal(ts.Frequency(b.sampling_rate),
                     ts.Frequency(2 * a.sampling_rate))
    npt.assert_equal(b.sampling_interval,
def test_Frequency():
    """Test frequency representation object"""
    tuc = ts.time_unit_conversion
    for unit in ['ns', 'ms', 's', None]:
        f = ts.Frequency(1, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit])
 
        f = ts.Frequency(1000, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit] / 1000)
 
        f = ts.Frequency(0.001, time_unit=unit)
        npt.assert_equal(f.to_period(), tuc[unit] * 1000)