Download the pickled Example Dataframe, which are basically two sine waves. Then just try to plot it:
import pandas
df = pandas.read_pickle("pd_example")
df.plot()
There are no labels at all for the index (x-axis).
A while ago I had labels as "0 days 00:00:xxx.xxxxx", but it is not the case anymore.
Tested on a fresh installation with same results as I have now (no labels).
pd.show_versions()commit: None
python: 3.6.3.final.0
python-bits: 64
OS: Windows
OS-release: 10
machine: AMD64
processor: Intel64 Family 6 Model 158 Stepping 9, GenuineIntel
byteorder: little
LC_ALL: None
LANG: None
LOCALE: None.None
pandas: 0.21.1
pytest: 3.3.2.dev44+gdb4df583
pip: 9.0.1
setuptools: 38.2.4
Cython: None
numpy: 1.13.3
scipy: 1.0.0
pyarrow: None
xarray: None
IPython: 6.2.1
sphinx: None
patsy: None
dateutil: 2.6.1
pytz: 2017.2
blosc: None
bottleneck: None
tables: None
numexpr: None
feather: None
matplotlib: 2.1.1
openpyxl: 1.7.0
xlrd: None
xlwt: None
xlsxwriter: None
lxml: None
bs4: None
html5lib: 1.0.1
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: 2.10
s3fs: None
fastparquet: None
pandas_gbq: None
pandas_datareader: None
How is DataFrame created? Overwriting index looks work.
df.index = pd.to_timedelta(np.arange(len(df)), unit='us')
df.plot()
# OK
Could you reproduce it using the dataframe as is? Does it mean that it is malformed somehow?
I am using this to generate the indexes:
>>>> time_line
array([ 0.00000000e+00, 1.00000000e-06, 2.00000000e-06, ...,
9.99997000e-01, 9.99998000e-01, 9.99999000e-01])
>>>> deltatime_line = pd.to_timedelta(time_line,unit="s")
>>>> df = pd.DataFrame(signal_matrix, columns=sig_names, index=deltatime_line)
For the sake of those of needs a (quick and dirty) solution till this gets fixed:
import pandas
df = pandas.read_pickle("pd_example")
df.plot()
timeunit = 'us' # assuming it is given in micro-seconds
fig = plt.gcf()
ax_ = plt.gca()
labels = ax_.get_xticks().tolist()
new_labels = pd.to_timedelta(labels, unit=timeunit, box=True)
ax_.set_xticklabels(new_labels );
fig.autofmt_xdate()

As a (non equivalent) alternative [based on this post]:
import matplotlib, datetime
from matplotlib import pyplot as plt
def timeTicks(x, pos):
d = datetime.timedelta(microseconds=x)
return str(d)
import pandas as pd
df = pd.read_pickle("pd_example")
ax = df.plot()
formatter = matplotlib.ticker.FuncFormatter(timeTicks)
ax.xaxis.set_major_formatter(formatter)
plt.gcf().autofmt_xdate()

Easier reproducible example:
seconds = np.arange(0, 1, 1e-4)
td_seconds = pd.to_timedelta(seconds, unit="s")
df = pd.DataFrame({'a': np.random.randn(len(td_seconds))}, index=td_seconds)
df.plot()
and with that I can confirm the regression.
If you increase the resolution from 1e-4 to 1e-2 (so > milliseconds), then it works correctly. I suppose this is related to the refactor of timedelta plot xlabel formatting that was done in 0.20 (https://github.com/pandas-dev/pandas/pull/15067)
I must add that the whole timdelta index plotting is broken
td_seconds = pd.to_timedelta([0,1,2,10,11,12], unit="s")
df = pd.DataFrame({'a': np.random.randn(len(td_seconds))}, index=td_seconds)
df.plot(marker='o')
Most helpful comment
As a (non equivalent) alternative [based on this post]: