Two ways to add data object for a vtkView.
1) Create a representation object, set the inputs for it by calling SetInputConnection() or SetInput(), then add representation for the view.
2) Use AddRepresentationFromInputConnection or AddRepresentationFromInput to create representation automatically.
from vtk import *
surfaceRepresentation = vtkRenderedSurfaceRepresentation()
sphere = vtkSphereSource()
sphere.SetPhiResolution( 100 )
sphere.SetThetaResolution( 100 )
surfaceRepresentation.SetInputConnection( sphere.GetOutputPort() )
view = vtkRenderView()
view.AddRepresentation( surfaceRepresentation )
view.SetInteractionMode( vtkRenderView.INTERACTION_MODE_3D )
view.ResetCamera()
view.GetInteractor().Start()
from vtk import *
source = vtkRandomGraphSource() #vtkGraphAlgorithm
source.SetNumberOfVertices(100)
source.SetNumberOfEdges(100)
source.SetStartWithTree(True)
view = vtkGraphLayoutView()
view.AddRepresentationFromInputConnection(source.GetOutputPort())
view.ResetCamera()
view.Render()
view.GetInteractor().Start()