id_plot_legis: Plot Person Ideal Points (Deprecated)

View source: R/Plot.R

id_plot_legisR Documentation

Plot Person Ideal Points (Deprecated)

Description

[Deprecated]

id_plot_legis() was renamed to id_plot_persons() for clarity and consistency.

Usage

id_plot_legis(
  object,
  return_data = FALSE,
  include = NULL,
  high_limit = 0.95,
  low_limit = 0.05,
  item_plot = NULL,
  item_plot_type = "non-inflated",
  text_size_label = 2,
  text_size_group = 2.5,
  point_size = 1,
  hjust_length = -0.7,
  person_labels = TRUE,
  group_labels = FALSE,
  person_ci_alpha = 0.2,
  show_true = FALSE,
  group_color = TRUE,
  hpd_limit = NULL,
  sample_persons = NULL,
  ...
)

Arguments

object

A fitted idealstan object or a named list of idealstan objects to compare across models

return_data

If true, the calculated legislator/bill data is returned along with the plot in a list

include

Specify a list of person/legislator IDs to include in the plot (all others excluded)

high_limit

The quantile (number between 0 and 1) for the high end of posterior uncertainty to show in plot

low_limit

The quantile (number between 0 and 1) for the low end of posterior uncertainty to show in plot

item_plot

The IDs (character vector) of the bill/item midpoints to overlay on the plot

item_plot_type

Whether to show the 'non-inflated' item/bill midpoints, the 'inflated' item/bill midpoints, or produce plots for 'both' kinds of models. Defaults to 'non-inflated' and will only display an item/bill midpoint if one has been specified in item_plot.

text_size_label

ggplot2 text size for legislator labels

text_size_group

ggplot2 text size for group text used for points

point_size

If person_labels and group_labels are set to FALSE, controls the size of the points plotted.

hjust_length

horizontal adjustment of the legislator labels

person_labels

if TRUE, use the person_id column to plot labels for the person (legislator) ideal points

group_labels

if TRUE, use the group column to plot text markers for the group (parties) from the person/legislator data

person_ci_alpha

The transparency level of the dot plot and confidence bars for the person ideal points

show_true

Whether to show the true values of the legislators (if model has been simulated)

group_color

If TRUE, give each group/bloc a different color

hpd_limit

The greatest absolute difference in high-posterior density interval shown for any point. Useful for excluding imprecisely estimated persons/legislators from the plot. Default is NULL if you don't want to exclude any.

sample_persons

If you don't want to use the full number of persons/legislators from the model, enter a proportion (between 0 and 1) to select only a fraction of the persons/legislators.

...

Other options passed on to plotting function, currently ignored

Value

A ggplot2 object showing legislator/person ideal points. Deprecated; use id_plot_persons instead.


idealstan documentation built on May 13, 2026, 1:08 a.m.