Changeset 7442:0c586b8a83fc in orange


Ignore:
Timestamp:
02/04/11 13:09:48 (3 years ago)
Author:
miha <miha.stajdohar@…>
Branch:
default
Convert:
12878b4fc97a6f815b734cf879bd4439f345318d
Message:

refactor to new Orange

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orange/doc/Orange/rst/code/network-graph-analyses.py

    r7438 r7442  
    1 import orange 
    2 from orngNetwork import Network 
    3 from orngNetwork import NetworkOptimization 
     1import Orange.network 
     2 
    43from pylab import * 
    54 
    65         
    76# vertices are placed randomly in NetworkOptimization constructor 
    8 network = NetworkOptimization() 
     7network = Orange.network.NetworkOptimization() 
    98 
    109# read network from file 
    11 net = Network.readNetwork("combination.net") 
     10net = Orange.network.Network.read("combination.net") 
    1211 
    1312components = net.getConnectedComponents() 
     
    4645print 
    4746 
    48 subnet = Network(net.getSubGraph([0, 1, 2, 3])) 
    49 subNetOptimization = NetworkOptimization(subnet) 
     47subnet = Orange.network.Network(net.getSubGraph([0, 1, 2, 3])) 
     48subNetOptimization = Orange.network.NetworkOptimization(subnet) 
    5049subNetOptimization.fruchtermanReingold(100, 1000) 
    5150 
Note: See TracChangeset for help on using the changeset viewer.