I have a list:
['Ad','Cs']
And a df
xx yy zz
Adjsl 5 7 9
Adjrr 1 1 2
Blsda 6 6 6
Csaosq 8 7 2
I would like to know how could I slice the df by only keeping the rows those index beggin with the elements of the list to obtain the following output:
xx yy zz
Adjsl 5 7 9
Adjrr 1 1 2
Csaosq 8 7 2