Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Addtional Row and Column methods available in other packages such as octave, R,.. #45

Closed
Gregor959 opened this issue Sep 7, 2012 · 2 comments
Assignees

Comments

@Gregor959
Copy link
Contributor

SORTING AND SHUFFLING:
SortByColumn -- similar to excel sort
SortByRow
ShuffleRows --puts rowvectors in a matrix in a random order
ShuffleColumns --puts columnvectos in a matrix in a random order.

FINDING AND SETTING SPECIFIC ELEMENTS:
FindMask(Predicate matchCondition) find a mask matrix of 0's and 1's where matchCondition is true.
OnMaskSet(Matrix mask, T value)
OnMaskApply(Matrix mask, Func<T, T> func) can apply a functin to all elements of a Mask Matrix.

e.g. in other languages:
A= Find(myMatrix<0)
myMatrix(A)=0;

//find elemets less than 0
var lessthanZero= myMatrix.FindMask(elem => (elem < 0.0))
// set them all to 0
myMatrix.OnMaskSet(lessthanZero, 0.0)

// a similar method:
FindIndices(Predicate matchCondition)

REMOVING AND SETTING SPECIFIC ROW AND COLUM RANGES:
RemoveColumn
RemoveRow
RemoveRowandColumn

SelectColumns ..selects all rows from a specified range of columns e.g. Matrix(:,10:12) would be selectColumns(10,3)
SelectRows ..selects all rows from a specified range of Rows e.g. Matrix(10:12,:) would be selectRows(10,3)
SetColumns
SetRows

@Gregor959 Gregor959 reopened this Sep 7, 2012
@Gregor959
Copy link
Contributor Author

Have written these methods and will have these methods available in a branch in less than 2 weeks.

@Gregor959
Copy link
Contributor Author

This is now available on my latest branch RowAndColAddOns:
1ed85a2

Gregor959@1ed85a2

@ghost ghost assigned cdrnet Sep 13, 2012
cdrnet added a commit that referenced this issue Apr 4, 2014
@cdrnet cdrnet added this to the v3.0 milestone Apr 12, 2014
@cdrnet cdrnet modified the milestones: v3.0.0-beta2, v3.0 May 2, 2014
@cdrnet cdrnet removed this from the v3.0.0-beta2 milestone Aug 12, 2014
@cdrnet cdrnet removed the 1 - Ready label Sep 8, 2016
@mathnet mathnet locked and limited conversation to collaborators Jul 24, 2021
@cdrnet cdrnet closed this as completed Jul 24, 2021

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants