FF.net.custom {FinNet}R Documentation

Represent a firm-firm (FF) network using the package network

Description

Create an object of class network from the package network using a FF matrix of class financial_matrix

Usage

FF.net.custom(
  x,
  vertex.size = NULL,
  vertex.colour = NULL,
  edge.width = NULL,
  edge.greyscale = NULL,
  directed = TRUE,
  loops = FALSE,
  weighted = any(x@M %in% c(0, 1)),
  ...
)

Arguments

x

A matrix-like object produced by FF and related functions

vertex.size

Which piece of information on the firms should be used to represent the nodes' size (see Details).

vertex.colour

Which piece of information on the firms should be used to represent the nodes' colours (see Details).

edge.width

Whether to use the edges' width to represent tie strength. Defaults to FALSE.

edge.greyscale

Whether to use the edges' colour to represent tie strength through a grey scale. Defaults to TRUE if the matrix is valued.

directed

Whether the network should be directed. Defaults to TRUE

loops

Whether the network should have loops. Defaults to FALSE

weighted

Whether the ties/edges should be weighted. Defaults to TRUE if any element of the matrix equals neither 0 nor 1

...

Aliases to the other parameters and additional settings (see Details).

Details

This function allows for a number of additional arguments.

Value

A network in the desired format

What can be passed to vertex.colour and vertex.size

The pieces of information that is possible to pass to vertex.size and vertex.colour are:

What can be passed to edge.width and edge.greyscale

The pieces of information that is possible to pass to edge.width and edge.greyscale are:

Additional parameters related to vertex.size

The effect of the additional parameters that modify the behaviour of vertex.size are:

vertex.size.max (defaults to 5):

vertex.size.min (defaults to 1):

Additional parameters related to vertex.colour

The only additional parameter related to vertex.colour is vertex.colour.palette. It supports a vector of RGB or named colours (see colours for all named colours in R). It also accepts complete calls to functions that return a such a vector like RColorBrewer::brewer.pal(n, name) or viridisLite::viridis(n, option). If the palette is too short, it will be extended automatically using colorRampPalette. If the palette is not declared, but this arguemnt is TRUE, it will defaulr to the following vector of colours:

If the argument is FALSE, NULL or NA, the vertex will be coloured of #081677 (Gentian blue).

Additional parameters related to edge.width

edge.width.max (defaults to 5):

edge.width.min (defaults to 1):

Additional parameters related to edge.greyscale

edge.greyscale.darkest (defaults to 5) :

edge.greyscale.fairest (defaults to 1):

Several aliases are accepted for all arguments, except M:

Author(s)

Telarico, Fabio Ashtar

See Also

FF.net FF.graph FF.graph.custom

Examples

# Create the network representation of the binary FF of
# Berkshire Hataway's holdings based on common ownership
data("firms_BKB")
x <- FF.naive.ownership(firms_BKB)
FF.net.custom(x = x, node.size = 3)


[Package FinNet version 0.1.2 Index]