To get the parameter of either a specfic base-pair/step or a DNA segment as a function of time.

        parameters
        ----------
        parameter : str
            Name of a base-pair or base-step or helical parameter.
            For details about accepted keywords, see ``parameter`` in the
            method :meth:`DNA.get_parameters`.

        bp : 1D list or array
            base-pairs to analyze
            Example: ::

                bp = [6]                                  # merge = False
                bp = [4,15]                               # merge = True

        merge : bool
            ``Default=False``. As shown above, if ``True``, bp should a list of
            range otherwise a list of single value. If ``bp = True``, the
            parameter for the respective DNA segment could be merged or
            calculated by ``merge_method``.

        merge_method : str
            Method to calculate the parameter of a DNA segment from local
            parameters of all base-pairs/steps that are between the range
            given through ``bp``.
            Currently accepted keywords are as follows:

                * ``merge_method = mean``: Average of local parameters
                * ``merge_method = sum``: Sum of local parameters

        masked : bool
            ``Default=False``. To skip specific frames/snapshots.
            ``DNA.mask`` array should be set to use this functionality.
            This array contains boolean (either ``True`` or ``False``) value
            for each frame to mask the frames. Presently, mask array is
            automatically generated during :meth:`DNA.generate_smooth_axis` to
            skip those frames where 3D fitting curve was not successful within
            the given criteria.


        Returns
        -------
        time : 1D array
            Array containing time of each frame from trajectory
        value : 1D array
            Array containing parameter values for each frame from trajectory

def time_vs_parameter(self, parameter, bp, merge=False, merge_method='mean', masked=False):
        """To get the parameter of either a specfic base-pair/step or a DNA segment as a function of time.

        parameters
        ----------
        parameter : str
            Name of a base-pair or base-step or helical parameter.
            For details about accepted keywords, see ``parameter`` in the
            method :meth:`DNA.get_parameters`.

        bp : 1D list or array
            base-pairs to analyze
            Example: ::

                bp = [6]                                  # merge = False
                bp = [4,15]                               # merge = True

        merge : bool
            ``Default=False``. As shown above, if ``True``, bp should a list of
            range otherwise a list of single value. If ``bp = True``, the
            parameter for the respective DNA segment could be merged or
            calculated by ``merge_method``.

        merge_method : str
            Method to calculate the parameter of a DNA segment from local
            parameters of all base-pairs/steps that are between the range
            given through ``bp``.
            Currently accepted keywords are as follows:

                * ``merge_method = mean``: Average of local parameters
                * ``merge_method = sum``: Sum of local parameters

        masked : bool
            ``Default=False``. To skip specific frames/snapshots.
            ``DNA.mask`` array should be set to use this functionality.
            This array contains boolean (either ``True`` or ``False``) value
            for each frame to mask the frames. Presently, mask array is
            automatically generated during :meth:`DNA.generate_smooth_axis` to
            skip those frames where 3D fitting curve was not successful within
            the given criteria.


        Returns
        -------
        time : 1D array
            Array containing time of each frame from trajectory
        value : 1D array
            Array containing parameter values for each frame from trajectory

        """
        if not (isinstance(bp, list) or isinstance(bp, np.ndarray)):
            raise AssertionError(
                "type %s is not list or np.ndarray" % type(bp))

        if (len(bp) > 1) and (merge == False):
            raise AssertionError(
                "bp %s contains more than two values, whereas merge=False. Use either one value in bp or merge=True" % bp)
            exit(1)

        if len(bp) == 1:
            merge = False

        if (merge == True) and not ((merge_method == 'mean') or (merge_method == 'sum')):
            raise AssertionError(
                "merge method %s is not available." % merge_method)

        # Masking values according to mask array
        midx = []
        if masked and self.mask is None:
            print(" WARNING: mask is not set. Mask is set during helical axis smoothing. \n")
            masked = False

        for i in range(len(self.time)):
            if masked:
                if self.mask[i] == False:
                    midx.append(i)
            else:
                midx.append(i)

        if len(bp) == 1:
            param_value, bp_idx = self.get_parameters(parameter, bp, bp_range=False, masked=masked)
        else:
            param_value, bp_idx = self.get_parameters(parameter, bp, bp_range=True, masked=masked)

        if (merge == True) and (merge_method == 'mean'):
            return self.time, np.mean(param_value, axis=0)

        elif (merge == True) and (merge_method == 'sum'):
            return self.time[midx], np.sum(param_value, axis=0)

        else:
            return self.time[midx], param_value[0]