There are several ways to do this,
One option is to use the transpose tool, placing the "field_male_female" as the header field and counting the number of respondents. Following that, you can use a multi-field formula to replace null values with zeros.
Before:
![](http://community.alteryx.com/legacyfs/online/images/rtaImage_eid=907E00000000bcw&feoid=Body&refid=0EME0000000UuAR.png)
Process:
![](http://community.alteryx.com/legacyfs/online/images/rtaImage_eid=907E00000000bcw&feoid=Body&refid=0EME0000000UuAM.png)
![](http://community.alteryx.com/legacyfs/online/images/rtaImage_eid=907E00000000bcw&feoid=Body&refid=0EME0000000UuAW.png)
Quick answer, so hope it makes sense!
Chris