Skip to content

Commit

Permalink
Don't need bold lines.
Browse files Browse the repository at this point in the history
  • Loading branch information
dereckmezquita committed Jul 29, 2024
1 parent 3a6f76c commit 9c8a822
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: interface
Type: Package
Title: A runtime type system for R; interfaces, enums, typed data.frames/data.tables and functions
Version: 0.0.4
Version: 0.0.41
URL: https://github.com/dereckmezquita/interface
Authors@R:
person(given = "Dereck",
Expand Down
8 changes: 4 additions & 4 deletions R/type.frame.R
Original file line number Diff line number Diff line change
Expand Up @@ -320,11 +320,11 @@ print.typed_frame <- function(x, ...) {
# Determine the base frame type
base_frame_type <- class(x)[2] # The second class should be the base frame type

cat("\033[1mTyped Data Frame Summary:\033[0m\n")
cat("Typed Data Frame Summary:\n")
cat(sprintf("Base Frame Type: %s\n", base_frame_type))
cat(sprintf("Dimensions: %d rows x %d columns\n", nrow(x), ncol(x)))

cat("\n\033[1mColumn Specifications:\033[0m\n")
cat("\nColumn Specifications:\n")
col_types <- attr(x, "col_types")
max_name_length <- max(nchar(names(col_types)))

Expand All @@ -333,12 +333,12 @@ print.typed_frame <- function(x, ...) {
cat(sprintf(" %-*s : %s\n", max_name_length, name, type_desc))
}

cat("\n\033[1mFrame Properties:\033[0m\n")
cat("\nFrame Properties:\n")
cat(sprintf(" Freeze columns : %s\n", ifelse(attr(x, "freeze_n_cols"), "Yes", "No")))
cat(sprintf(" Allow NA : %s\n", ifelse(attr(x, "allow_na"), "Yes", "No")))
cat(sprintf(" On violation : %s\n", attr(x, "on_violation")))

cat("\n\033[1mData Preview:\033[0m\n")
cat("\nData Preview:\n")
print(as.data.frame(head(x, 5)))

if (nrow(x) > 5) {
Expand Down

0 comments on commit 9c8a822

Please sign in to comment.