def _get_series_result_type(result, objs=None):
from pandas import SparseSeries, SparseDataFrame, DataFrame<EOL>if isinstance(result, dict):<EOL><INDENT>if all(isinstance(c, (SparseSeries, SparseDataFrame))<EOL>for c in result.values()):<EOL><INDENT>return SparseDataFrame<EOL><DEDENT>else:<EOL><INDENT>return DataFrame<EOL><DEDENT><DEDENT>if result._block.is_sparse:<EOL><INDENT>return SparseSeries<EOL><DEDENT>else:<EOL><INDENT>return objs[<NUM_LIT:0>]._constructor<EOL><DEDENT>
return appropriate class of Series concat
input is either dict or array-like