Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #93308

Re: Matplotlib X-axis timezone trouble

Path csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed7.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.057
X-Spam-Evidence '*H*': 0.89; '*S*': 0.00; 'dst': 0.07; 'bug': 0.10; 'cc:addr:python-list': 0.10; '1),': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'wrote:': 0.16; 'handling': 0.20; 'cc:2**0': 0.21; 'cc:addr:python.org': 0.21; 'produces': 0.22; 'am,': 0.23; '2015': 0.23; 'header:In-Reply- To:1': 0.24; 'message-id:@mail.gmail.com': 0.28; 'matplotlib': 0.29; 'solution,': 0.29; 'code': 0.31; 'skip:d 20': 0.32; 'skip:p 30': 0.32; 'pacific': 0.33; 'though.': 0.33; 'running': 0.34; 'received:google.com': 0.34; 'subject:: ': 0.37; 'tue,': 0.38; 'skip:p 20': 0.38; 'things': 0.39; 'subject:-': 0.39; 'helps': 0.61; '30,': 0.63; 'sounds': 0.72; 'chrisa': 0.84; 'to:none': 0.90; '2014,': 0.91; 'angeles': 0.91
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=XVo6ZCC8/nHhU29qAXlj5hiLemcEqlV/DEt420kRVIE=; b=Azb6dIw73JfQ3BSup4HU0yBWWXfE0dVwe9M5hwJgg7M/YcQEwYl562RwfnLJBdx5MQ by9cMTnsNoP5iVrNvEMzBBykfDhV3PNFcFgYv3m9AqzU2wadVcrgI+zJBiXYCH6qENfr MIEHv8pUIvYfOiBVsCkzQ3t4PTVyx2vt55HrKId5uQTjQzbHYt1EXq4EeyDYqyMsNfye pv3PO/r/5+i7B6W4pF5U93ngnKZxzZBMOTf6DaEMZjMA7IUlPBZ7er0ZCXTXaYnKxJW7 Mxu4wwquZtBAgXGAYRCzse/HaIGeU/+Fau+qxwXfsz55MLRQKPwchdrPhpBvLNJsb5y0 oT5A==
MIME-Version 1.0
X-Received by 10.50.43.196 with SMTP id y4mr20097844igl.14.1435630291916; Mon, 29 Jun 2015 19:11:31 -0700 (PDT)
In-Reply-To <cve7ppFk1viU1@mid.individual.net>
References <cve7ppFk1viU1@mid.individual.net>
Date Tue, 30 Jun 2015 12:11:31 +1000
Subject Re: Matplotlib X-axis timezone trouble
From Chris Angelico <rosuav@gmail.com>
Cc "python-list@python.org" <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20+
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.179.1435630294.3674.python-list@python.org> (permalink)
Lines 16
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1435630294 news.xs4all.nl 2843 [2001:888:2000:d::a6]:42640
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:93308

Show key headers only | View raw


On Tue, Jun 30, 2015 at 10:56 AM, Peter Pearson
<pkpearson@nowhere.invalid> wrote:
> The following code produces a plot with a line running from (9:30, 0) to
> (10:30, 1), not from (8:30, 0) to (9:30, 1) as I desire.
>
> pacific = pytz.timezone("US/Pacific")
> plt.plot([datetime.datetime(2014, 10, 7, 8, 30, tzinfo=pacific),
>           datetime.datetime(2014, 10, 7, 9, 30, tzinfo=pacific)],
>          [0,1], marker="o", color="green")

Sounds to me like a bug in DST handling - in October 2014, Los Angeles
was on Pacific Daylight Time, which would give a one-hour offset if
matplotlib is handling things on the basis of Pacific Standard Time. I
don't know if that helps at all with figuring out a solution, though.

ChrisA

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-06-30 00:56 +0000
  Re: Matplotlib X-axis timezone trouble Laura Creighton <lac@openend.se> - 2015-06-30 04:03 +0200
    Re: Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-06-30 04:57 +0000
  Re: Matplotlib X-axis timezone trouble Chris Angelico <rosuav@gmail.com> - 2015-06-30 12:11 +1000
    Re: Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-06-30 04:49 +0000
      Re: Matplotlib X-axis timezone trouble Chris Angelico <rosuav@gmail.com> - 2015-06-30 17:01 +1000
        Re: Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-06-30 16:42 +0000
          Re: Matplotlib X-axis timezone trouble Chris Angelico <rosuav@gmail.com> - 2015-07-01 02:55 +1000
  Re: Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-07-01 05:50 +0000
    Re: Matplotlib X-axis timezone trouble Chris Angelico <rosuav@gmail.com> - 2015-07-01 17:15 +1000
      Datetime timezone trouble (was: Matplotlib X-axis timezone trouble) Peter Pearson <pkpearson@nowhere.invalid> - 2015-07-01 16:36 +0000
        Re: Datetime timezone trouble (was: Matplotlib X-axis timezone trouble) Ian Kelly <ian.g.kelly@gmail.com> - 2015-07-01 10:55 -0600
          Re: Datetime timezone trouble (was: Matplotlib X-axis timezone trouble) Peter Pearson <pkpearson@nowhere.invalid> - 2015-07-01 19:09 +0000
        Re: Datetime timezone trouble (was: Matplotlib X-axis timezone trouble) Chris Angelico <rosuav@gmail.com> - 2015-07-02 03:08 +1000
  Re: Matplotlib X-axis timezone trouble Akira Li <4kir4.1i@gmail.com> - 2015-07-04 07:29 +0300
    Re: Matplotlib X-axis timezone trouble [SOLVED] Peter Pearson <pkpearson@nowhere.invalid> - 2015-07-04 17:37 +0000
  Re: Matplotlib X-axis timezone trouble Tony the Tiger <tony@tiger.invalid> - 2015-07-09 19:50 +0000
    Re: Matplotlib X-axis timezone trouble Peter Pearson <pkpearson@nowhere.invalid> - 2015-07-10 16:15 +0000

csiph-web