473,322 Members | 1,501 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Need 3d graphics library in python

Hi all,
Iam a newbie in python and i need a library that supports 3D graphics in Python. My requirement is to construct a network (graph) out of it..I installed Networkx. This is a simple program i tried out ..The error iam getting is

Program
-------------
import networkx as NX
from networkx import *

G=Graph()
G.add_node(1)
G.add_nodes_from([2,3])
G.add_edge((1,2))
draw(G)

Error
--------
================================

Traceback (most recent call last):
File "C:/Python25/test.py", line 8, in <module>
draw(G)
NameError: name 'draw' is not defined


Tell me whether i hv to include any other library , inorder for the drawing functions in Networkx to work correctly.
Apr 2 '08 #1
3 2555
jlm699
314 100+
You have to include the networkx.drawing library to make use of draw, draw_random, draw_circular, and draw_spectral .
Apr 2 '08 #2
You have to include the networkx.drawing library to make use of draw, draw_random, draw_circular, and draw_spectral .

Hi,
Thanx for the reply. In the documentation of networkx , they says that
NetworkX does not provide sophisticated graph drawing tools. We
396 do provide elementary drawing tools as well as an interface to use the
397 open source Graphviz software package. These reside in networkx.drawing, 398 and will be imported if possible.

Is this is wht u meant ????
from networkx.drawing import * ..Pls forgive me to ask these simple qns..Also pls tell me is it possible to create 3d graphics in networkx

Thanx in advance..
Apr 3 '08 #3
Hi,
I got it working right ... The problem was i hv not yet downloaded the packages like matplotlib,numpy etc. I more important qn. to ask u..Is it possible to draw 3d graphs in it ..

Thanx..
Apr 3 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Steven Feil | last post by:
I am wondering if there is a light weight Python library for producing web graphics on-the-fly. There is a C-language library called gd that can be used in a CGI program to produce gif images. The...
0
by: Eric Hanson | last post by:
Hi, I'm interested in doing some work with 3d graphics visualizations of XML/RDF data in Python. I know Python is strong on the XML front but what about 3d graphics? Is there a graphics...
16
by: Neal | last post by:
Hi, I saw the VB6 Code to do this at this link: http://www.dotnet247.com/247reference/msgs/11/56581.aspx The VB6 Code reads as follows: Private Type Rect Left As Long
7
by: Michael Galvin | last post by:
I am trying to use Python to send to the printer a calender filled with a mix of text and simple graphics. I want to draw on the printed page something like a table with 6 rows and 7 columns to...
2
by: utab | last post by:
Dear all, Could you please recommend me a graphics library for python. I saw PYX which has nice screenshots on the webpage. My first ambition is to be able to draw 2D or 3D graphs for my...
2
by: Lloyd Dupont | last post by:
In my .NET application I have some text rendered through GDI. It draws and print nicely. Now I would like to implement image export. So I create a new System.Drawing.Bitmap(width, height) then...
3
by: Paulo da Silva | last post by:
I need to make some data representation. Basically a major window for a 2D chart, a scrollable window with some few small 2D graphics. The rest is a normal form with buttons, labels and entries....
5
by: tomy | last post by:
Hi All I am a newbie to turtle graphics in python, so sorry if you find this question too easy. How can I get smoother lines in turtle graphics? I am using python on windows. Thanks in advance
3
by: t | last post by:
I have been learning C++ on my own. For some projects, I would like to use graphics. What is the easiest way to do this? (I am using Visual Studio Express 2005.) Separate from the ease of use...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.