Skip to content

Commit 158069e

Browse files
add assign documentation
1 parent 768b76c commit 158069e

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

src/Operations/Assign.jl

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ end
2828
"""
2929
GrB_Vector_assign(w, mask, accum, u, I, ni, desc)
3030
31+
Assign values from one GraphBLAS vector to a subset of a vector as specified by a set of
32+
indices. The size of the input vector is the same size as the index array provided.
33+
3134
# Examples
3235
```jldoctest
3336
julia> using SuiteSparseGraphBLAS
@@ -82,6 +85,9 @@ end
8285
"""
8386
GrB_Matrix_assign(C, Mask, accum, A, I, ni, J, nj, desc)
8487
88+
Assign values from one GraphBLAS matrix to a subset of a matrix as specified by a set of
89+
indices. The dimensions of the input matrix are the same size as the row and column index arrays provided.
90+
8591
# Examples
8692
```jldoctest
8793
julia> using SuiteSparseGraphBLAS
@@ -138,6 +144,10 @@ end
138144
"""
139145
GrB_Col_assign(C, Mask, accum, u, I, ni, j, desc)
140146
147+
Assign the contents a vector to a subset of elements in one column of a matrix.
148+
Note that since the output cannot be transposed, a different variant of assign is provided
149+
to assign to a row of matrix.
150+
141151
# Examples
142152
```jldoctest
143153
julia> using SuiteSparseGraphBLAS
@@ -198,6 +208,10 @@ end
198208
"""
199209
GrB_Row_assign(C, mask, accum, u, i, J, nj, desc)
200210
211+
Assign the contents a vector to a subset of elements in one row of a matrix.
212+
Note that since the output cannot be transposed, a different variant of assign is provided
213+
to assign to a column of a matrix.
214+
201215
# Examples
202216
```jldoctest
203217
julia> using SuiteSparseGraphBLAS
@@ -258,6 +272,9 @@ end
258272
"""
259273
GrB_Vector_assign(w, mask, accum, x, I, ni, desc)
260274
275+
Assign the same value to a specified subset of vector elements.
276+
With the use of `GrB_ALL`, the entire destination vector can be filled with the constant.
277+
261278
# Examples
262279
```jldoctest
263280
julia> using SuiteSparseGraphBLAS
@@ -343,6 +360,9 @@ end
343360
"""
344361
GrB_Matrix_assign(C, Mask, accum, x, I, ni, J, nj, desc)
345362
363+
Assign the same value to a specified subset of matrix elements.
364+
With the use of `GrB_ALL`, the entire destination matrix can be filled with the constant.
365+
346366
# Examples
347367
```jldoctest
348368
julia> using SuiteSparseGraphBLAS

0 commit comments

Comments
 (0)