% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/misc.r
\name{dput2}
\alias{dput2}
\title{Wrapper function around dput to provide more options}
\usage{
dput2(x, comment = FALSE, obj = NULL, collapse = NULL, ...)
}
\arguments{
\item{x}{An object passed to \code{dput}}

\item{comment}{logical indicating if comment characters should be prepended to results}

\item{obj}{character of length one indicating the name of the object that should be prepended to result}

\item{collapse}{character of length one with the collapse character. If provided the result will be pasted with this collapse character}

\item{...}{additional arguments passed to dput}
}
\value{
a vector with the result from dput
}
\description{
This function wraps around the dput function and provide more options to save result
in a vector
}
\examples{

dput2(setNames(runif(5),letters[1:5]))

}
\author{
Richard Hooijmaijers
}
