Is it possible to delete a line in a datatable programattically?

Say I have counted the number of lines in the datatable using fd.control(datatable1).length, and I see one line has a particular value in a column, could I remove that line using javascript?

for example something like:

var table = fd.control(datatable1).value;

table.forEach(function(line){
if (line.Column1 === 'Remove Me'){
line.remove();
}
});

Obviously I made up remove() but is there a function that will do this in a DataTable?

Kind regards

Andy

Dear @abolam,
The lines are stored as an array, so you can use the following methods:
fd.control('DataTable1').value.pop();
Or this
fd.control('DataTable1').value.shift();
Also, check this to remove specific items - How can I remove a specific item from an array in JavaScript? - Stack Overflow

PS. Don't remove them while iterating through the array with a loop, or you might remove next item you have to check, and get an error.