passing both arbitary and defined options
- To: mathgroup at smc.vnet.net
- Subject: [mg98421] passing both arbitary and defined options
- From: Eddie <eddie at webassign.net>
- Date: Thu, 9 Apr 2009 05:56:30 -0400 (EDT)
So I'm building a plotting function, and I want it to be able to inherit the same options that a ListPlot[] command can inherit, so my prototype looks like this: NewPlot[data_List,options___Rule]:=Module[{},blah blah blah ListPlot[fancy stuff,options] ] Here's the rub, if I additionally want to create a NewPlot-specific option, it doesn't mesh. For example: NewPlot[data_List,OptionsPattern[{newOption->newValue}],options___Rule] := etc Options contains the rule for newOption when NewPlot is called with that option utilized, and ListPlot throws an error because it's not a recognized option for ListPlot. Is there a way I can have my personally declared options and the wildcard options both present and working? Is there a way to "Drop" the rule that matches the user-defined option from 'options'?