diff --git a/pandas/core/format.py b/pandas/core/format.py index 1db0e0b41b3e3..003b1fefd01f7 100644 --- a/pandas/core/format.py +++ b/pandas/core/format.py @@ -103,7 +103,7 @@ def _get_footer(self): if getattr(self.series.dtype,'name',None): if footer: footer += ', ' - footer += 'Dtype: %s' % com.pprint_thing(self.series.dtype.name) + footer += 'dtype: %s' % com.pprint_thing(self.series.dtype.name) return unicode(footer) diff --git a/pandas/core/series.py b/pandas/core/series.py index 726216dde2269..72d31443213c7 100644 --- a/pandas/core/series.py +++ b/pandas/core/series.py @@ -3305,7 +3305,7 @@ def _repr_footer(self): namestr = "Name: %s, " % str( self.name) if self.name is not None else "" - return '%s%sLength: %d, Dtype: %s' % (freqstr, namestr, len(self), + return '%s%sLength: %d, dtype: %s' % (freqstr, namestr, len(self), com.pprint_thing(self.dtype.name)) def to_timestamp(self, freq=None, how='start', copy=True): diff --git a/pandas/tests/test_format.py b/pandas/tests/test_format.py index 177ef3f9e3371..dbe697927b0b8 100644 --- a/pandas/tests/test_format.py +++ b/pandas/tests/test_format.py @@ -155,7 +155,7 @@ def test_to_string_repr_unicode(self): line = line.decode(get_option("display.encoding")) except: pass - if not line.startswith('Dtype:'): + if not line.startswith('dtype:'): self.assert_(len(line) == line_len) # it works even if sys.stdin in None @@ -1081,7 +1081,7 @@ def test_float_trim_zeros(self): 2.03954217305e+10, 5.59897817305e+10] skip = True for line in repr(DataFrame({'A': vals})).split('\n'): - if line.startswith('Dtype:'): + if line.startswith('dtype:'): continue if _three_digit_exp(): self.assert_(('+010' in line) or skip) @@ -1143,7 +1143,7 @@ def test_to_string(self): cp.name = 'foo' result = cp.to_string(length=True, name=True, dtype=True) last_line = result.split('\n')[-1].strip() - self.assertEqual(last_line, "Freq: B, Name: foo, Length: %d, Dtype: float64" % len(cp)) + self.assertEqual(last_line, "Freq: B, Name: foo, Length: %d, dtype: float64" % len(cp)) def test_freq_name_separation(self): s = Series(np.random.randn(10), @@ -1199,7 +1199,7 @@ def test_float_trim_zeros(self): vals = [2.08430917305e+10, 3.52205017305e+10, 2.30674817305e+10, 2.03954217305e+10, 5.59897817305e+10] for line in repr(Series(vals)).split('\n'): - if line.startswith('Dtype:'): + if line.startswith('dtype:'): continue if _three_digit_exp(): self.assert_('+010' in line) diff --git a/pandas/tests/test_series.py b/pandas/tests/test_series.py index 28572e2eae015..f846a28ff78b7 100644 --- a/pandas/tests/test_series.py +++ b/pandas/tests/test_series.py @@ -142,7 +142,7 @@ def test_multilevel_name_print(self): "qux one 7", " two 8", " three 9", - "Name: sth, Dtype: int64"] + "Name: sth, dtype: int64"] expected = "\n".join(expected) self.assertEquals(repr(s), expected) diff --git a/pandas/tseries/tests/test_timeseries.py b/pandas/tseries/tests/test_timeseries.py index 2b42fc5c42542..215aa32b8bbb1 100644 --- a/pandas/tseries/tests/test_timeseries.py +++ b/pandas/tseries/tests/test_timeseries.py @@ -568,7 +568,7 @@ def test_series_repr_nat(self): '1 1970-01-01 00:00:00.000001\n' '2 1970-01-01 00:00:00.000002\n' '3 NaT\n' - 'Dtype: datetime64[ns]') + 'dtype: datetime64[ns]') self.assertEquals(result, expected) def test_fillna_nat(self):