필터 지우기
필터 지우기

Where is the 'up' property/function defined for biograph nodes/edges?

조회 수: 1 (최근 30일)
Corey
Corey 2015년 12월 13일
편집: Corey 2015년 12월 17일
Using biograph library, nodes and edges have a property or function called 'up' that is used all over the library, looks like I have to use 'up' in order to implement the new functionality I am trying to add. I think it simply returns the graph that the node/edge object belongs to, but I am not sure. Where is this 'up' property or function defined?
For instance, this code uses this 'up' property/function.
cm = [0 1 1 0 0;1 0 0 1 1;1 0 0 0 0;0 0 0 0 1;1 0 1 0 0];
bg = biograph(cm);
upbg = bg.Nodes(1).up
This returns
Biograph object with 5 nodes and 9 edges.
Problem is, I can't find a property or function called 'up' anywhere. I can't find it in the documentation, it is not defined in the @node/scheme.m file, and there is no @node/up.m function, calls to "get(bg.Nodes(1))" does not show any 'up' property, in the debugger it steps over any line of code referring to 'up' as if it were a property, and I can't seem to find any place in the code where an 'up' property variable is actually set on any node or edge, the inspector window does not list this attribute.
What is this edge/node 'up' property or method, where is it defined?

채택된 답변

Corey
Corey 2015년 12월 17일
편집: Corey 2015년 12월 17일
I think I figured it out. I think 'up' parameter points to the parent biograph object for all nodes/edges in a biograph. I believe it is defined and set in the constructor. For instance, in @biograph/@node/node.m:
connect(h,hPar,'up')
I don't know where the connect() function is defined though, so I don't know what else it does.

추가 답변 (1개)

Walter Roberson
Walter Roberson 2015년 12월 13일

카테고리

Help CenterFile Exchange에서 Network Analysis and Visualization에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by