How to hide fields in subforms based on input in other fields in the same sub-form?

How to hide fields in subforms based on input in other fields in the same sub-form?

I use a subform in my mainform that contents a row with 4 fields. How can I hide some of these fields in the row based on the input added into this row-fields?