Convert the trans column to a factor. Use tidyr's complete to fill (non-NA) dummy values for the missing factor levels in each class group. Follow M-M's suggestion setting showlegend to TRUE for a single group and legendgroup to trans to link the legend entries between subplots. Oct 10, 2021 &183; plotly Main interface to plotly; plotly Initiate a plotly visualization; plotlybuild 'Build. 2022. 6. 26. &0183;&32;Parameters. dataframe (DataFrame or array-like or dict) This argument needs to be passed for column names (and not keyword names) to be used.Array-like and dict are tranformed internally to a pandas DataFrame. Optional if missing, a DataFrame gets constructed under the hood using the other arguments. x (str or int or Series or array-like) Either a name.