Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7446239
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T12:16:12+00:00 2026-05-29T12:16:12+00:00

I created the following function with six args: nDone <- function(under,strike,ttoe,vol,rf,dy) { pnorm(((log(under/strike)+ (rf-dy+(vol^2)/2)*ttoe)/(vol*(ttoe^0.5))))

  • 0

I created the following function with six args:

nDone <- function(under,strike,ttoe,vol,rf,dy) {
    pnorm(((log(under/strike)+ (rf-dy+(vol^2)/2)*ttoe)/(vol*(ttoe^0.5))))
}

nDone(90,100,3,0.17,0.05,0)
# Result: 
[1] 0.6174643

Now I create a vector with the same values in an object, and try to call the function using the vector, but get the following error:

d <- c(90,100,3,0.17,0.05,0)

nDone(d)

Error in under/strike : 'strike' is missing

What am I doing wrong and how to fix?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T12:16:14+00:00Added an answer on May 29, 2026 at 12:16 pm

    Try this

     do.call(nDone, as.list(d))
    

    Explanation of what’s happening in your first attempt by @joran from the comments:

    R is seeing you pass a single argument to nDone, namely the vector d, which is handed off to the first function argument, under. Since you haven’t specified a default value for the others, they are missing and hence the error

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I created the following function to simplify a piece of particularly complex code. CREATE
I created the following interface: <?php interface Action { public function execute(\requests\Request $request, array
In external (Delphi-created) DLL I've got the following function that I need to call
I created a class A and wrote the following function foo() class A {
On my page, the following function has been created: <SCRIPT language=javascript type=text/javascript> function popModData(
I created following shortcode function to call a menu on a specific location on
I've used following function in some of my projects, but recently I've created a
I have created the following function for checking the connection status: private void checkConnectionStatus()
I have created following function to fill field of a form page, there is
I have created the following function: public void DelegatedCall(Action<Object> delegatedMethod) And defined the following

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.