% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/public_finances.R
\name{get_psnb}
\alias{get_psnb}
\title{Get Public Sector Net Borrowing (PSNB)}
\usage{
get_psnb(refresh = FALSE)
}
\arguments{
\item{refresh}{Logical. If \code{TRUE}, re-download even if a cached copy exists.
Defaults to \code{FALSE}.}
}
\value{
An \code{obr_tbl} with the standard v0.4.0 schema. \code{series} is
\code{"PSNB"}, \code{metric_type} is \code{"level"}, \code{unit} is \code{"gbp_bn"}. See
\code{\link[=get_public_finances]{get_public_finances()}} for column definitions.
}
\description{
Downloads (and caches) the OBR Public Finances Databank and returns
annual Public Sector Net Borrowing in \enc{£}{GBP} billion. A positive
value means the government is borrowing (deficit); a negative value means
a surplus.
}
\examples{
\donttest{
op <- options(obr.cache_dir = tempdir())
try({
  psnb <- get_psnb()
  tail(psnb)
})
options(op)
}

}
\seealso{
Other public finances: 
\code{\link{get_expenditure}()},
\code{\link{get_psnd}()},
\code{\link{get_public_finances}()},
\code{\link{get_receipts}()}
}
\concept{public finances}
