Skip to main content
5 votes
2 answers
209 views

I have a dataset of 150 individual cows (150 IDs) with 288 GPS locations per day and for 10 days, where each row is a relocation (432.000 rows) and columns store cow's ID, a time stamp (date and time)...
cmoreno's user avatar
  • 115
3 votes
2 answers
109 views

I have a matrix M with size (37, N) and an additionnal 1D reference vector of size (37,1) I am looking for a way to compute the spearman correlation between each sample of M and my reference to obtain ...
QuanticDisaster's user avatar
1 vote
1 answer
81 views

I am using graph-tool to plot an adjacency matrix from a dataframe. The adjacency matrix looks correct and symmetric, but when I plot it using graph-tool, the resulting visualization is incorrect. (I ...
JYB's user avatar
  • 23
2 votes
2 answers
67 views

I want to do exactly the same thing as this post, but in python; aka given a list of natural integers, generate a random adjacency matrix whose degrees would match the list. I had great hope as the ...
Qise's user avatar
  • 276
1 vote
1 answer
128 views

How to convert a graph to a sparse ‘dgTmatrix’ in one step? library(igraph) library(Matrix) g <- make_ring(5) adj <- as_adjacency_matrix(g, sparse = TRUE) class(adj) # [1] "dgCMatrix" #...
clp's user avatar
  • 1,602
1 vote
0 answers
34 views

It's relatively easy to see that, for a network with Adjacency matrix A, the number of 3-loops is (1/6)Tr(A^3). For 4-loops, we need (1/8)[Tr(A^4) - 2(sigma(k^2)) + sigma(k)] where k are the node ...
Aydin Onac's user avatar
0 votes
0 answers
85 views

The data x and y represent the geographic coordinates of the centroids of cities 1 to 8: > df <- data.frame( + ID = 1:8, + x = c(4.0, 7.0, 2.5, 8.0, 3.0, 5.0, 6.0, 7.0), + y = c(8, 9, 4, 5,...
César Macieira's user avatar
0 votes
1 answer
54 views

I have a dataframe that consists of x rows and n columns. Each row represents a document and each column represents a category of tag associated with the document. The values in each cell are a 0 (...
PositivePotato90's user avatar
0 votes
1 answer
54 views

In our problem, rows (index) and columns belong to the same category of objects. We want to enlarge a Pandas DataFrame, adding rows and columns filled with NaNs or predefined values, so that both the ...
Mateusz's user avatar
  • 49
3 votes
3 answers
99 views

I have a dataframe of this structure: A <- data.frame(A = c("B",NA,NA,NA), B = c("C","D",NA,NA), C = c(NA,NA,NA,NA), ...
tony13s's user avatar
  • 191
0 votes
1 answer
240 views

I am working on a fraud detection project using GNN. My graph has banking codes (SWIFT BIC codes) as nodes and the edges represent transactions. Below are the shapes of my tensors: Node Features ...
Marie-Lyne Roustom's user avatar
2 votes
2 answers
84 views

The following is a seemingly simple recursion for finding a hybercube matrix. The recursion is defined as: (Formula) I tried to put it into code but I keep running into broadcasting issues with numpy. ...
mo-alowais's user avatar
0 votes
1 answer
59 views

For the follwoing data that represents the flow of the tourist by months for these five countries, I would like to draw a multiple bar plot such that one row of the mutliple bar plot represents the ...
Pankaj's user avatar
  • 23
1 vote
3 answers
210 views

What is a good way to define this graph data structure: typedef struct { unsigned short isExists : 1; WEIGHT_TYPE weight; } Weight; typedef struct { Weight adjacencyMatrix[VERTICES_NUM][...
Lior v's user avatar
  • 540
0 votes
1 answer
77 views

I'm experiencing a strange exception when calling the fit_predict method on a PageRank object, with data coming from an edge list. I get the 'TypeError: The input matrix must be in Scipy sparse format ...
Herve Kabla's user avatar

15 30 50 per page
1
2 3 4 5
61