pwrs.core.get_reorder#
- pwrs.core.get_reorder.get_reorder(A, idx, dim)[source]#
Extract reordered slices along a specified dimension.
Mirrors MATPOWER’s
get_reorderhelper by selecting rows or columns from an array-like input using one-based indices along the requested dimension.- Parameters:
A (array_like or sparse matrix) – Input data to reorder.
idx (array_like) – One-based indices to extract.
dim (int) – One-based dimension along which to reorder.
nargout (int, optional) – MATLAB compatibility flag.
- Returns:
Reordered slice of
A.- Return type:
Any