Posts by Igor da Silva Paixão • 101 points
3 posts
-
5
votes3
answers1099
viewsA: How to divide the elements of a matrix by the average of its column
It probably solves your problem A <- matrix(1:16, ncol = 4) apply(A, 2, function(x) x/mean(x)) The second row can be described as "Apply the function to the second dimension(columns) of the…
-
1
votes2
answers313
viewsA: How to access the pointer of a struct within the pointer of another struct?
No place where you point out how error has a small concept flaw (grafo_A)->Vertice[i]->num_vertice = vertices[i]; (grafo_A) is a logo pointer -> is correct... You access Vertice however you…
-
1
votes2
answers99
viewsA: Doubt classes c++
The STL includes several data structures to the developer one of them is the vector, which is a dynamic vector, there are several other structures a quick search and you will see its resources. This…