82093

Error in namespaceExport(ns, exports) : undefined exports: … Error: package or namespace load failed

Question:

I recently updated R to the latest version (R version 3.1.1) and now I can´t run load packages. In the case of ggplot2, the error message after running library("ggplot2") is

*Error in namespaceExport(ns, exports) : undefined exports: ContinuousRange, DiscreteRange, abs_area, alpha, area_pal, as.trans, asn_trans, atanh_trans, boxcox_trans, brewer_pal, cbreaks, censor, col2hcl, comma, comma_format, cscale, date_breaks, date_format, date_trans, dichromat_pal, discard, div_gradient_pal, dollar, dollar_format, dscale, exp_trans, expand_range, extended_breaks, format_format, fullseq, gradient_n_pal, grey_pal, hue_pal, identity_pal, identity_trans, is.trans, linetype_pal, log10_trans, log1p_trans, log2_trans, log_breaks, log_trans, logit_trans, manual_pal, math_format, muted, parse_format, percent, percent_format, pretty_breaks, probability_trans, probit_trans, reciprocal_trans, rescale, rescale_max, rescale_mid, rescale_none, rescale_pal, reverse_trans, scientific, scientific_format, seq_gradient_pal, shape_pal, show_col, sqrt_trans, squish, squish_infinite, time_trans, trans_breaks, trans_format, trans_new, trans_range, zero_range Además: Mensajes de aviso perdidos S3 methods 'fullseq.Date', 'fullseq.POSIXt', 'fullseq.numeric', 'print.trans' were declared in NAMESPACE but not found Error: package or namespace load failed for 'ggplot2'*

For package BiodiversityR, the error message ends with

*Error: package or namespace load failed for 'BiodiversityR'*

I've tried several tricks like re-installing, updating, loading in previous R versions, including 32-bit versions.

sessionInfo: R version 3.1.1 (2014-07-10) Platform: x86_64-w64-mingw32/x64 (64-bit) locale: [1] LC_COLLATE=Spanish_Mexico.1252 LC_CTYPE=Spanish_Mexico.1252 [3] LC_MONETARY=Spanish_Mexico.1252 LC_NUMERIC=C [5] LC_TIME=Spanish_Mexico.1252 attached base packages: [1] tcltk stats graphics grDevices utils datasets methods [8] base other attached packages: [1] xtable_1.7-3 reshape2_1.4 nlme_3.1-117 plyr_1.8.1 loaded via a namespace (and not attached): [1] colorspace_1.2-4 digest_0.6.4 grid_3.1.1 gtable_0.1.2 [5] lattice_0.20-29 munsell_0.4.2 proto_0.3-10 Rcpp_0.11.1 [9] stringr_0.6.2 tools_3.1.1 packageVersion("ggplot2") [1] '1.0.0'

Answer1:

Indeed, one or more of the dependend packages had to be updated.

I created a new empty library directory where I re-installed all packages and this solved the problem. Thanks!

My error was updating only ggplot2 update.packages("ggplot2") while I should have ran update.packages().

Answer2:

I often find simply retrying with require() works for some reason: require(BiodiversityR)

Recommend

  • GC pauses of 5 seconds but mark, sweep and compact take less than 1 second
  • Add Custom Labels to Axes in Highcharts
  • Writing a spreadsheet using CFspreadsheet to avoid error this file might be corrupted
  • Writing to stdin from PHP?
  • Jquery form no submission to IE7 and IE8
  • Excel graphics with ggplot2
  • SQL query results into php table
  • Display Google Analytics Data in View
  • How do I scale a linked image inside an SVG from top (currently scaling from center oddly)
  • How do we select top 20% and bottom 80% records in sql server
  • Get PHP to update with every line returned from a shell command
  • Ajax image upload where image gets datetimestamp added to FILENAME and image title get's insert
  • Two Datatables in One Page
  • Ruby - insert into an array based on a percentage
  • ImportError: Could not import the Python Imaging Library (PIL) required to load image files on tenso
  • Help in cleaning Code-39 Barcode data in Java
  • Incorporating an incrementing value into this sql
  • Uploading a file using ajax and php
  • Is URLEncoder.encode(string, “UTF-8”) a poor validation?
  • Image width after load returns 0
  • Mysql Self Join to find a parent child relationship in the same table
  • Puppet - Escaping YAML variables for Hiera
  • How to replace with percent character in cmd.exe?
  • select random rows seed in sql server
  • How to refer to a variable in Batch Scripting?
  • calculate measure for some members that create some percent of total measure
  • Google Chart HTML Tooltip displays html text
  • how to increase progressbar when i write xml?
  • argparse doesn't check for positional arguments
  • Which JVM Flag sets the GC overhead threshold mentioned in the G1Ergonomics log?
  • How to use aliases in query for making conditions in mysql
  • Sending post data nsurlsession
  • How to use EXTRACT through dbplyr when connecting to an Oracle DB
  • dplyr idiom for “select A, B, max(C) from D group by C”
  • Should the plus in tel URIs be encoded?
  • Progress Bar in Python Console on Windows
  • two ways of displaying a decimal
  • PHP mysql_real_escape_string() and % character
  • Pie Chart Labels Cut off
  • Why does my regular expression fail with certain substitutions?