Suggested .octaverc for GNU Octave

Octave uses startup.m persistent user settings like Matlab. To keep Matlab compatibility, put Octave-specific startup commands and plotting defaults into ~/.octaverc.

Suggested ~/.octaverc

This is a suggested “~/.octaverc”, edit to your tastes. It sets default parameters for all GNU Octave sessions on your computer.

suppress_verbose_help_message(1)
page_output_immediately(1)
page_screen_output(0)
crash_dumps_octave_core(0)
sigterm_dumps_octave_core(0)
sighup_dumps_octave_core(0)

EDITOR('nano > /dev/tty 2>&1 < /dev/tty %s')

if exist('~/Documents/MATLAB/startup.m', 'file')
  source('~/Documents/MATLAB/startup.m')
endif
*_dumps_*
eliminate nuisance octave-workspace files that appear when Octave is ctrl-c exited or crashes.
page_output_immediately(1)
make Octave print immediately like Matlab.
if exist
use startup.m file like Matlab.

Set plot defaults

Particularly useful for HiDPI systems, control Octave default plot text size of axes and titles, useful for HiDPI systems by adding to “~/.octaverc”:

set(0, "defaultaxesfontsize", 16)
set(0, "defaultlinelinewidth", 2)

adjust 16 to produce the most appealing text labels in:

  • axes tick labels
  • legend key
  • title text

defaultline is the root category for lines, so defaultlinelinewidth is not a typo.

Speedup Octave start (without GUI)

Be sure you’re not autoloading Octave packages

Notes