c.diffnet | R Documentation |

Combining `diffnet`

objects that share time periods and attributes names, but
vertices ids (only valid for diffnet objects that have an empty intersection
between vertices ids).

```
## S3 method for class 'diffnet'
c(..., recursive = FALSE)
```

`...` |
diffnet objects to be concatenated. |

`recursive` |
Ignored. |

The diffnet objects in `...`

must fulfill the following conditions:

Have the same time range,

have the same vertex attributes, and

have an empty intersection of vertices ids,

The meta data regarding `undirected`

, `value`

, and `multiple`

are set to `TRUE`

if any of the concatenating diffnet objects has that
meta equal to `TRUE`

.

The resulting diffnet object's columns in the vertex attributes ordering (both dynamic and static) will coincide with the first diffnet's ordering.

A new `diffnet`

object with as many vertices as the sum of each
concatenated diffnet objects' number of vertices.

Other diffnet methods:
`%*%()`

,
`as.array.diffnet()`

,
`diffnet-arithmetic`

,
`diffnet-class`

,
`diffnet_index`

,
`plot.diffnet()`

,
`summary.diffnet()`

```
# Calculate structural equivalence exposure by city -------------------------
data(medInnovationsDiffNet)
# Subsetting diffnets
city1 <- medInnovationsDiffNet[medInnovationsDiffNet[["city"]] == 1]
city2 <- medInnovationsDiffNet[medInnovationsDiffNet[["city"]] == 2]
city3 <- medInnovationsDiffNet[medInnovationsDiffNet[["city"]] == 3]
city4 <- medInnovationsDiffNet[medInnovationsDiffNet[["city"]] == 4]
# Computing exposure in each one
city1[["expo_se"]] <- exposure(city1, alt.graph="se", valued=TRUE)
city2[["expo_se"]] <- exposure(city2, alt.graph="se", valued=TRUE)
city3[["expo_se"]] <- exposure(city3, alt.graph="se", valued=TRUE)
city4[["expo_se"]] <- exposure(city4, alt.graph="se", valued=TRUE)
# Concatenating all
diffnet <- c(city1, city2, city3, city4)
diffnet
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.