3-dimensional plot in Python?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • questions?

    #1

    3-dimensional plot in Python?

    I want to make a 3d plot. x is a vector(discrete ), y is also a
    vector(discrete ), for each pairwise x,y I have a value z(x,y)(it is not
    a function, just discrete values for each pair of x,y)

    I want to show them on a two dimensional plot by showing z(x,y) with
    colors.

    Thanks for any hint

  • Lee Harr

    #2
    Re: 3-dimensional plot in Python?

    On 2005-11-11, questions? <universal_used @hotmail.com> wrote:[color=blue]
    > I want to make a 3d plot. x is a vector(discrete ), y is also a
    > vector(discrete ), for each pairwise x,y I have a value z(x,y)(it is not
    > a function, just discrete values for each pair of x,y)
    >
    > I want to show them on a two dimensional plot by showing z(x,y) with
    > colors.
    >[/color]


    Download matplotlib for free. Matplotlib is a python library for making publication quality plots using a syntax familiar to MATLAB users. Matplotlib uses numpy for numerics.

    Comment

    • Frithiof Andreas Jensen

      #3
      Re: 3-dimensional plot in Python?


      "questions? " <universal_used @hotmail.com> wrote in message
      news:1131736814 .721116.16890@g 14g2000cwa.goog legroups.com...[color=blue]
      > I want to make a 3d plot. x is a vector(discrete ), y is also a
      > vector(discrete ), for each pairwise x,y I have a value z(x,y)(it is not
      > a function, just discrete values for each pair of x,y)
      >
      > I want to show them on a two dimensional plot by showing z(x,y) with
      > colors.
      >
      > Thanks for any hint
      >[/color]

      SciPy is your friend: Provides interfaces to several plot engines, including
      gnuplot.


      Comment

      • Robert Kern

        #4
        Re: 3-dimensional plot in Python?

        Frithiof Andreas Jensen wrote:[color=blue]
        > "questions? " <universal_used @hotmail.com> wrote in message
        > news:1131736814 .721116.16890@g 14g2000cwa.goog legroups.com...
        >[color=green]
        >>I want to make a 3d plot. x is a vector(discrete ), y is also a
        >>vector(discre te), for each pairwise x,y I have a value z(x,y)(it is not
        >>a function, just discrete values for each pair of x,y)
        >>
        >>I want to show them on a two dimensional plot by showing z(x,y) with
        >>colors.
        >>
        >>Thanks for any hint[/color]
        >
        > SciPy is your friend: Provides interfaces to several plot engines, including
        > gnuplot.[/color]

        Those interfaces are long since deprecated. Please use matplotlib instead.

        Download matplotlib for free. Matplotlib is a python library for making publication quality plots using a syntax familiar to MATLAB users. Matplotlib uses numpy for numerics.


        --
        Robert Kern
        rkern@ucsd.edu

        "In the fields of hell where the grass grows high
        Are the graves of dreams allowed to die."
        -- Richard Harter

        Comment

        • Frithiof Andreas Jensen

          #5
          Re: 3-dimensional plot in Python?


          "Robert Kern" <robert.kern@gm ail.com> wrote in message
          news:mailman.69 4.1132061080.18 701.python-list@python.org ...
          [color=blue]
          > Those interfaces are long since deprecated. Please use matplotlib instead.
          >
          > http://matplotlib.sf.net[/color]

          "Long since" being .... When?

          I recently installed SciPy and it did not say anything about "deprecated "!


          Comment

          • Lonnie Princehouse

            #6
            Re: 3-dimensional plot in Python?

            Google for "MayaVi"

            It's overkill for what you've described (it doesn't even make 2D graphs
            afaik), but it could draw your function as a 3D surface. And besides,
            it's way cool.

            Comment

            • Robert Kern

              #7
              Re: 3-dimensional plot in Python?

              Frithiof Andreas Jensen wrote:[color=blue]
              > "Robert Kern" <robert.kern@gm ail.com> wrote in message
              > news:mailman.69 4.1132061080.18 701.python-list@python.org ...
              >[color=green]
              >>Those interfaces are long since deprecated. Please use matplotlib instead.
              >>
              >>http://matplotlib.sf.net[/color]
              >
              > "Long since" being .... When?
              >
              > I recently installed SciPy and it did not say anything about "deprecated "![/color]

              Only xplt ever got much developer TLC. For the past year or two,
              whenever someone comes to the mailing list asking about some problem
              with {x,g,wx}plt, we've been referring them to matplotlib. During the
              transition to the new scipy_core, all of them have been moved to the
              sandbox/ directory and won't be returning. If you're using xplt, some
              people mentioned that they might be interested in maintaining it, but it
              will have to be forked off into it's own project.

              --
              Robert Kern
              rkern@ucsd.edu

              "In the fields of hell where the grass grows high
              Are the graves of dreams allowed to die."
              -- Richard Harter

              Comment

              • François Pinard

                #8
                Re: 3-dimensional plot in Python?

                [Frithiof Andreas Jensen]
                [color=blue]
                > [universal_used@ hotmail.com][/color]
                [color=blue][color=green]
                >> I want to make a 3d plot. x is a vector(discrete ), y is also
                >> a vector(discrete ), for each pairwise x,y I have a value z(x,y)(it is
                >> not a function, just discrete values for each pair of x,y). I want
                >> to show them on a two dimensional plot by showing z(x,y) with colors.[/color][/color]
                [color=blue]
                >SciPy is your friend: Provides interfaces to several plot engines, including
                >gnuplot.[/color]

                For such things, I like R (from http://www.r-project.org), for which
                also exist a few Python interfaces (I use http://rpy.sourceforge.net).
                For communication between Python and R, Python Numeric facilities are
                usable, yet not required. Moreover, with 3D-accelerated cards or
                simulations thereof, OpenGL tools (see http://rgl.neoscientists.org)
                allow you to interactively wander into your plot, somehow.

                The combination is worth. What may appear as a drawback is the need to
                become acquainted with R, the system and the language. But if you
                happen to do scientific works, this really is a worth investment.

                --
                François Pinard http://pinard.progiciels-bpi.ca

                Comment

                • François Pinard

                  #9
                  Re: 3-dimensional plot in Python?

                  [Frithiof Andreas Jensen]
                  [color=blue]
                  > [universal_used@ hotmail.com][/color]
                  [color=blue][color=green]
                  >> I want to make a 3d plot. x is a vector(discrete ), y is also
                  >> a vector(discrete ), for each pairwise x,y I have a value z(x,y)(it is
                  >> not a function, just discrete values for each pair of x,y). I want
                  >> to show them on a two dimensional plot by showing z(x,y) with colors.[/color][/color]
                  [color=blue]
                  >SciPy is your friend: Provides interfaces to several plot engines, including
                  >gnuplot.[/color]

                  For such things, I like R (from http://www.r-project.org), for which
                  also exist a few Python interfaces (I use http://rpy.sourceforge.net).
                  For communication between Python and R, Python Numeric facilities are
                  usable, yet not required. Moreover, with 3D-accelerated cards or
                  simulations thereof, OpenGL tools (see http://rgl.neoscientists.org)
                  allow you to interactively wander into your plot, somehow.

                  The combination is worth. What may appear as a drawback is the need to
                  become acquainted with R, the system and the language. But if you
                  happen to do scientific works, this really is a worth investment.

                  --
                  François Pinard http://pinard.progiciels-bpi.ca

                  Comment

                  Working...