Libraryless. Click here for Pure Java version (2424L/16K).
static PosNegMatrix<LS> posNegMatrixForRegexpIC(S regexp, Cl<S> pos, Cl<S> neg) { PosNegMatrix<LS> matrix = posNegMatrixOfLists(); for (S s : pos) (containsRegexpIC(s, regexp) ? matrix.pos : matrix.falseNeg).add(s); for (S s : neg) (containsRegexpIC(s, regexp) ? matrix.falsePos : matrix.neg).add(s); ret matrix; }
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
Snippet ID: | #1027472 |
Snippet name: | posNegMatrixForRegexpIC - for testing a regexp on pos/neg examples |
Eternal ID of this version: | #1027472/2 |
Text MD5: | 9675f65697eb4baf7877989b6de20da7 |
Transpilation MD5: | 674859069d1f875c60e01da1a1a789e7 |
Author: | stefan |
Category: | javax / a.i. |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-03-22 14:07:38 |
Source code size: | 337 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 183 / 276 |
Version history: | 1 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) #1027493 - posNegMatrixForNGrams |