% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/graphon_generation.R
\name{sample_graphon}
\alias{sample_graphon}
\title{Generates a graph given a graphon}
\usage{
sample_graphon(W, n)
}
\arguments{
\item{W}{A graphon given by a matrix}

\item{n}{The number of nodes of the sampled graph}
}
\value{
A graph sampled from the graphon W with n nodes
}
\description{
Generates a graph given a dense graphon W.
}
\examples{
library(igraph)
W <- matrix(0.2, nrow = 100, ncol = 100)
gr <- sample_graphon(W, n= 100)

}
