MATLAB: How do i Filter out table columns headers based on given query words

datadatabaseimporting excel dataMATLABtable

Dear Experiences
i have a table that look like the following:
Table:
Name RC BV CC RQ CY ..... TY
A1 1 0 1 0 1 0
A2 1 0 0 0 0 0
A3 0 1 1 0 1 0
A4 0 0 0 0 0 1
then for the given query word such as ( A1 ) then the result perhaps store in cell array like:
Result ={ RC , CC , CY ,…} where the values of A1 in the corresponding columns header are 1.
i would thanks any one can give me help.

Best Answer

YourTable.Properties.VariableNames( logical(YourTable{1,:}) )