I dont understand this

Asked by renkoino on 2011-01-05

I don't understand why the array size of A, labels and xy are not the same. As far as I know, A is a matrix which contain number of how many times a node links to the other. Labels should be the list of all nodes. And xy is representing the co-ordinate of all nodes. However as shown in the cs-standford.mat, matrix A is 9914X9914, labels is 9914X1, and xy is 21X2 ! why?
Ken

Question information

Language:
English Edit question
Status:
Answered
For:
Matlab BGL Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:

This question was reopened

Revision history for this message
David Gleich (dgleich) said :
#1

The get_matlab_bgl_options function is in the private directory. To
get at the functions in this directory, the entire matlab_bgl archive
must be on your path.

David

On Wed, Jan 5, 2011 at 7:37 AM, renkoino
<email address hidden> wrote:
> New question #140268 on Matlab BGL:
> https://answers.launchpad.net/matlab-bgl/+question/140268
>
> Hi, I have a problem with the matlab_bgl 4.0.1 installation.
> according to the instruction that I found at http://www.stanford.edu/~dgleich/programs/matlab_bgl/matlab_bgl_v2.1.pdf, I typed clustering_coefficients(sparse(ones(5))). But here is the error reponse
>
> ??? undefined function or vvariable 'get_matlab_bgl_options'
>
> error in ==> clustering_coefficients at 45
> [trans check full2sparse] = get_matlab_bgl_options
>
> Now, let's say I didn't add to the right path, so what made the error message?
> thank you.
>
> --
> You received this question notification because you are an answer
> contact for Matlab BGL.
>

Revision history for this message
David Gleich (dgleich) said :
#2

cs-stanford.mat does not contain an xy variable. That must be a
hold-over from another graph.

David

On Wed, Jan 5, 2011 at 12:26 PM, renkoino
<email address hidden> wrote:
> Question #140268 on Matlab BGL changed:
> https://answers.launchpad.net/matlab-bgl/+question/140268
>
> Summary changed to:
> I dont understand this
>
> Description changed to:
> I don't understand why the array size of A, labels and xy are not the same. As far as I know, A is a matrix which contain number of how many times a node links to the other. Labels should be the list of all nodes. And xy is representing the co-ordinate  of all nodes. However as shown in the cs-standford.mat, matrix A is 9914X9914, labels is 9914X1, and xy is 21X2 ! why?
> Ken
>
> --
> You received this question notification because you are an answer
> contact for Matlab BGL.
>

Revision history for this message
renkoino (tuqui8) said :
#3

Thanks David Gleich, that solved my question.

Revision history for this message
renkoino (tuqui8) said :
#4

Hi David

My name is Ken. First of all, I'd like to say thank you for all helps from you.
Actually, I am very surprised when finding your work in the file exchange central of mathwork.com. So, I immediately downloaded it to matlab and tried to run. Anyway, I have not get used to the library yet so I have still have some questions.

I want a shortest path from the source node S to a Nth node in the network. my purpose is to make an array A = [N, pred(N), (pred(pred(n)),..., S]. Do you know how can I interfere into the library to alter the library to alter the algorithm?

Thanks.

Ken.

Revision history for this message
David Gleich (dgleich) said :
#5

I think the function you want is pred_to_path or something like that.

David

On Wed, Jan 5, 2011 at 1:56 PM, renkoino
<email address hidden> wrote:
> Question #140268 on Matlab BGL changed:
> https://answers.launchpad.net/matlab-bgl/+question/140268
>
>    Status: Solved => Open
>
> renkoino is still having a problem:
> Hi David
>
> My name is Ken. First of all, I'd like to say thank you for all helps from you.
> Actually, I am very surprised when finding your work in the file exchange central of mathwork.com. So, I immediately downloaded it to matlab and tried to run. Anyway, I have not get used to the library yet so I have still have some questions.
>
> I want a shortest path from the source node S to a Nth node in the
> network. my purpose is to make an array A = [N, pred(N),
> (pred(pred(n)),..., S]. Do you know how can I interfere into the library
> to alter the library to alter the algorithm?
>
>
> Thanks.
>
>
> Ken.
>
> --
> You received this question notification because you are an answer
> contact for Matlab BGL.
>

Can you help with this problem?

Provide an answer of your own, or ask renkoino for more information if necessary.

To post a message you must log in.