I have a pandas dataframe as following named as df
I want to convert this dataframe to a bytes string which is having type bytes i.e when I enter type(df) it should give me an output of Bytes instead of pandas.core.frame.DataFrame The output should look like following:
b'Age,Height,Weight,City\r\n23,5.45,67,New York\r\n' 