久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<tfoot id='3FeNG'></tfoot>
<i id='3FeNG'><tr id='3FeNG'><dt id='3FeNG'><q id='3FeNG'><span id='3FeNG'><b id='3FeNG'><form id='3FeNG'><ins id='3FeNG'></ins><ul id='3FeNG'></ul><sub id='3FeNG'></sub></form><legend id='3FeNG'></legend><bdo id='3FeNG'><pre id='3FeNG'><center id='3FeNG'></center></pre></bdo></b><th id='3FeNG'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='3FeNG'><tfoot id='3FeNG'></tfoot><dl id='3FeNG'><fieldset id='3FeNG'></fieldset></dl></div>
    <legend id='3FeNG'><style id='3FeNG'><dir id='3FeNG'><q id='3FeNG'></q></dir></style></legend>

      • <bdo id='3FeNG'></bdo><ul id='3FeNG'></ul>
    1. <small id='3FeNG'></small><noframes id='3FeNG'>

        使用 Matplotlib 繪制時間戳(小時/分鐘/秒)

        Plotting timestamps (hour/minute/seconds) with Matplotlib(使用 Matplotlib 繪制時間戳(小時/分鐘/秒))

          <tfoot id='HFR8B'></tfoot>
          <i id='HFR8B'><tr id='HFR8B'><dt id='HFR8B'><q id='HFR8B'><span id='HFR8B'><b id='HFR8B'><form id='HFR8B'><ins id='HFR8B'></ins><ul id='HFR8B'></ul><sub id='HFR8B'></sub></form><legend id='HFR8B'></legend><bdo id='HFR8B'><pre id='HFR8B'><center id='HFR8B'></center></pre></bdo></b><th id='HFR8B'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='HFR8B'><tfoot id='HFR8B'></tfoot><dl id='HFR8B'><fieldset id='HFR8B'></fieldset></dl></div>

          <small id='HFR8B'></small><noframes id='HFR8B'>

            <bdo id='HFR8B'></bdo><ul id='HFR8B'></ul>

                  <tbody id='HFR8B'></tbody>
              • <legend id='HFR8B'><style id='HFR8B'><dir id='HFR8B'><q id='HFR8B'></q></dir></style></legend>

                1. 本文介紹了使用 Matplotlib 繪制時間戳(小時/分鐘/秒)的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我想繪制一些時間戳(年-月-日時-分-秒格式).我正在使用以下代碼,但它沒有顯示任何小時-分鐘-秒信息,它將它們顯示為 00-00-00.我仔細檢查了我的日期數組,從下面的代碼片段可以看出,它們不為零.

                  I want to plot some timestamps (Year-month-day Hour-Minute-Second format). I am using the following code, however it doesn't show any hour-minute-second information, it shows them as 00-00-00. I double checked my date array, and as you can see from the snippet below, they are not zero.

                  你知道我為什么會得到 00-00-00 的任何想法嗎?

                  Do you have any idea about why I am getting 00-00-00's?

                  import matplotlib.pyplot as plt
                  import matplotlib.dates as md
                  import dateutil
                  
                  dates = [dateutil.parser.parse(s) for s in datestrings]
                  # datestrings = ['2012-02-21 11:28:17.980000', '2012-02-21 12:15:32.453000', '2012-02-21 23:26:23.734000', '2012-02-26 17:42:15.804000']
                  plt.subplots_adjust(bottom=0.2)
                  plt.xticks( rotation= 80 )
                  ax=plt.gca()
                  xfmt = md.DateFormatter('%Y-%m-%d %H:%M:%S')
                  ax.xaxis.set_major_formatter(xfmt)
                  plt.plot(dates[0:10],plt_data[0:10], "o-")
                  plt.show()
                  

                  推薦答案

                  嘗試放大圖表,您會看到日期時間隨著 x 軸比例的變化而擴大.

                  Try zooming in on your graph, you will see the datetimes expand as your x axis scale changes.

                  在 matplotlib 中繪制 unix 時間戳

                  在嘗試繪制染色體上正選擇的熱圖時,我遇到了類似的煩人問題.如果我縮小得太遠,事情就會完全消失!

                  I had a similarly annoying problem when trying to plot heatmaps of positive selection on chromosomes. If I zoomed out too far things would disappear entirely!

                  此代碼完全按照您提供的日期繪制日期,但不會在兩者之間添加刻度.

                  edit: This code plots your dates exactly as you give them, but doesn't add ticks in between.

                  import matplotlib.pyplot as plt
                  import matplotlib.dates as md
                  import dateutil
                  
                  datestrings = ['2012-02-21 11:28:17.980000', '2012-02-21 12:15:32.453000', '2012-02-21 23:26:23.734000', '2012-02-26 17:42:15.804000']
                  dates = [dateutil.parser.parse(s) for s in datestrings]
                  
                  plt_data = range(5,9)
                  plt.subplots_adjust(bottom=0.2)
                  plt.xticks( rotation=25 )
                  
                  ax=plt.gca()
                  ax.set_xticks(dates)
                  
                  xfmt = md.DateFormatter('%Y-%m-%d %H:%M:%S')
                  ax.xaxis.set_major_formatter(xfmt)
                  plt.plot(dates,plt_data, "o-")
                  plt.show()
                  

                  這篇關于使用 Matplotlib 繪制時間戳(小時/分鐘/秒)的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  python: Two modules and classes with the same name under different packages(python:不同包下同名的兩個模塊和類)
                  Configuring Python to use additional locations for site-packages(配置 Python 以使用站點包的其他位置)
                  How to structure python packages without repeating top level name for import(如何在不重復導入頂級名稱的情況下構造python包)
                  Install python packages on OpenShift(在 OpenShift 上安裝 python 包)
                  How to refresh sys.path?(如何刷新 sys.path?)
                  Distribute a Python package with a compiled dynamic shared library(分發帶有已編譯動態共享庫的 Python 包)

                  <small id='QmROk'></small><noframes id='QmROk'>

                  • <bdo id='QmROk'></bdo><ul id='QmROk'></ul>
                  • <legend id='QmROk'><style id='QmROk'><dir id='QmROk'><q id='QmROk'></q></dir></style></legend>

                        <i id='QmROk'><tr id='QmROk'><dt id='QmROk'><q id='QmROk'><span id='QmROk'><b id='QmROk'><form id='QmROk'><ins id='QmROk'></ins><ul id='QmROk'></ul><sub id='QmROk'></sub></form><legend id='QmROk'></legend><bdo id='QmROk'><pre id='QmROk'><center id='QmROk'></center></pre></bdo></b><th id='QmROk'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='QmROk'><tfoot id='QmROk'></tfoot><dl id='QmROk'><fieldset id='QmROk'></fieldset></dl></div>
                          <tbody id='QmROk'></tbody>
                          <tfoot id='QmROk'></tfoot>
                          1. 主站蜘蛛池模板: 麻豆精品一区二区三区在线观看 | 亚洲网在线 | 成人在线a | 欧美一卡二卡在线 | 亚洲视频www | 自拍视频网站 | 99热精品久久 | 中文字幕精品一区 | 韩日在线 | 精品欧美视频 | 一区二区三区欧美 | 欧美区日韩区 | 成人亚洲性情网站www在线观看 | 精品免费国产一区二区三区 | 国际精品鲁一鲁一区二区小说 | 大香在线伊779 | 精品国产视频 | 精品亚洲国产成av人片传媒 | 久久三级av | 91精品久久久久久久久中文字幕 | 久久久人成影片一区二区三区 | 欧美日韩高清一区 | 中文字幕第十五页 | 人成在线视频 | 天天干天天玩天天操 | 欧美大片久久久 | 国产亚洲成av人片在线观看桃 | 一区二区三区四区国产 | 在线看亚洲 | 日本网站免费在线观看 | 亚洲欧美一区二区三区在线 | 久久免费精品 | 久久久综合 | 国产精品天堂 | 亚洲精品自拍视频 | 精品免费国产一区二区三区 | 久久久久久久久蜜桃 | 国产高清在线精品一区二区三区 | 中文字幕电影在线观看 | 91精品国产综合久久久久久 | 国产精品中文字幕在线 |