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

  • Home
  • SEARCH
  • 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 6365283
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T00:16:26+00:00 2026-05-25T00:16:26+00:00

I am programming R and am confronted with the following syntax errorÖ Here is

  • 0

I am programming R and am confronted with the following syntax errorÖ

Here is the code:

for (i in (1:7)) {for (index in seq(i,56,8)) {values[[length(values)+1]] <- c(ADDLINEORDER[index]) } time_series_values[[length(time_series_value)+1]] <- values}

Error: unexpected symbol in "for (i in (1:7)) {for (index in seq(i,56,8)) {values[[length(values)+1]] <- c(ADDLINEORDER[index]) }  time_series_values"

what I want is: lets say that there is a vector (1,5,6,7,3,9) as input

As I result I want to have it like ((1,6,3),(5,7,9))

1 5 are the starting points, I want it to be iterated by 2 so (1, 6, 9) are together in one list.

Thanks

  • 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-25T00:16:27+00:00Added an answer on May 25, 2026 at 12:16 am

    @Spacedman has found the problem. Formatting properly also fixes it:

    for ( i in (1:7) ) {
      for ( index in seq(i, 56, 8) ) {
        values[[ length(values) + 1 ]] <- c( ADDLINEORDER[index] ) 
      }
      time_series_values[[ length(time_series_value) + 1 ]] <- values
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

during programming with VBScript I write a lot of error-check code in functions before
Programming Student here...trying to work on a project but I'm stuck. The project is
Programming PHP in Eclipse PDT is predominately a joy: code completion, templates, method jumping,
Programming is learned by writing programs. But code reading is said to be another
Programming novice here. I'm trying to allow a user to enter their name, firstName
In Programming Pearls I have met the following problem. The question is this: print
While programming with python I am often confused with the following ambiguity: should it
Programming newbie here, about a month in with Ruby. I'm currently playing around with
Which programming language(s) were used to code Windows Vista?
assembly programming in Emacs how to? I want Emacs to do following things 1.

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.