% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/layout-target-saqr.R
\name{layout_target}
\alias{layout_target}
\title{Target Layout (focal-node, topological)}
\usage{
layout_target(network, target = NULL, horizontal = TRUE, equalize = TRUE, ...)
}
\arguments{
\item{network}{A \code{CographNetwork} or \code{cograph_network} object.}

\item{target}{Node of interest, given as a label (character) or 1-based
index. When \code{NULL} (default) the highest-degree node is used.}

\item{horizontal}{Logical. If \code{TRUE} (default) levels flow left to right
with the target node on the left; if \code{FALSE} they flow top to bottom.}

\item{equalize}{Logical. If \code{TRUE} (default) nodes are evenly spaced
within each level.}

\item{...}{Additional arguments (ignored).}
}
\value{
Data frame with \code{x}, \code{y} coordinates, one row per node.
}
\description{
Port of qgraph's \code{flow()} layout. One node of interest (the
\code{target}) is placed alone, then every other node is drawn in successive
levels ordered by unweighted graph distance (BFS hops) from it. This shows
how the target node connects out into the rest of the network.
}
\details{
Unlike qgraph's implementation, weights are binarized for layering (only
connectivity matters) and disconnected nodes are placed in an extra trailing
level instead of raising an error.
}
\examples{
adj <- matrix(c(0, 1, 1, 0, 1, 0, 0, 1,
                1, 0, 0, 0, 0, 1, 0, 0), nrow = 4, byrow = TRUE)
net <- CographNetwork$new(adj)
layout_target(net, target = 1)

}
