Questions tagged [variable-length]

Refers to anything whose length can vary

Refers to anything whose length can vary

290 questions
0
votes
1 answer

Is necessary to specify a length of Integer when create a table in SQLITE?

I understand that if you know the length of the value you'll receive you must specify the length. e.g. you will receive a text string with length of 20 always, you specify it when you create your table My question is: i'll receive integers but…
Carlos Mayoral
  • 313
  • 3
  • 12
0
votes
1 answer

Why the result of function merge is larger than the original data

For example, if the x is a matrix of two variables (Time and X,the length is len1),and y is a matrix of two variables (Time and Y, the length is len2), I just want to merge x and y, using the following code: > x Time Value 1…
Cheng
  • 193
  • 3
  • 10
0
votes
0 answers

How to deal "Error in model.frame.default(formula = y ~x ) variable lengths differ (found for)" in IRLS function

I'm trying use iteratively reweighted least squares method to estimate the coefficient of equation: y = a0 + a1 * cos(2*pi/365 * x) + b1 * sin(2*pi/365 * x) + c1 * x When I use IRLS to fit this equation I get an error: x <-…
user3689959
  • 9
  • 1
  • 5
0
votes
1 answer

Prolog Length of Evens in a List

I am a Prolog beginner, and I have the following length function: mylen([H|Lc],N) :- mylen(Lc,M),N is M+1. mylen([],0). I would like to know if there's an easy way to query the interpreter to calculate the length of the list of evens in a list,…
Domn Werner
  • 572
  • 2
  • 10
  • 20
0
votes
2 answers

Brightness plot (or image) with rows corresponding to arrays of varying length

I am using Python with numpy, scipy, matplotlib. I have two lists containing arrays of varying length, which for concreteness I will call x and y and say they look like (the actual arrays are on the order of ~1000 elements in length, and the actual…
user3558855
  • 303
  • 4
  • 17
0
votes
3 answers

Echo x number of dots based on the length of the file name

I'm trying to find a way to echo x number of dots based on the length of the file name. In the Batch-script I'm making, there is a part where it ECHO's the file name and size of a file. The problem is that none of the file names do have the same…
MokiTa
  • 4,760
  • 3
  • 15
  • 16
0
votes
2 answers

ListBox GetSelectedIndices Count vs Length

In my web application, I created a ListBox that is populated with a list of items. I have been doing some research and discovered that I can count the number of selected items with the code below in my IF statement. Using C#, aspx If…
Jayarikahs
  • 75
  • 11
0
votes
1 answer

How to get length of json object array?

I wrote a restService and my service returns me two different result : {"Response":…
Ozkan Ciftci
  • 89
  • 1
  • 11
0
votes
1 answer

Decode MIDI variable length field

How to decode variable length fields in MIDI? The description found at[1] does only give some examples without mentioning what happens if the most significant bit is set. This is my current code: uint32_t MuStudio::MIDI::FileReader::varfieldGet() …
user877329
  • 6,717
  • 8
  • 46
  • 88
0
votes
2 answers

Variable length initializer_list

Is there in c++ a possibility to create a variable length initializer_list? As Example: std::list mylist { somemagic (listSize, "default") }; Or: QList anotherList { somemagic (listSize, {MyClassInitializerHere} ) };
eddy
  • 488
  • 5
  • 18
0
votes
7 answers

RegEx - 1 to 10 Alphanumeric Spaces Okay

New to Regular Expressions. Thanks in advance! Need to validate field is 1-10 mixed-case alphanumeric and spaces are allowed. First character must be alphanumeric, not space. Good Examples: "Larry King" "L King1" "1larryking" "L" Bad Example: "…
0
votes
2 answers

C++ qsort array of pointers not sorting

I am trying to sort a buffer full of variable-length records alphabetically in C++. I previously asked how to implement this, and was told to sort an array of pointers to the records. I set up an array of pointers, but realized that each pointer…
bsg
  • 825
  • 2
  • 14
  • 34
0
votes
2 answers

Dropping observations in SAS based on length

I have a dataset that I'm trying to create tables from but I need to filter out the observations that don't belong in those tables. I'm still learning my way around SAS, so I don't know how to drop the observations using conditions. Basically I want…
kksf
  • 55
  • 1
  • 2
  • 10
0
votes
1 answer

Difference between these two SAS programs?

data work.temp; length A B 4; infile ''; input A B; run; data work.temp; length A 4 B 4; infile ''; input A B; run; Is there any difference between these two?
zhuoer
  • 617
  • 1
  • 7
  • 15
0
votes
0 answers

plm error variable lengths differ

I'm completely new to R, and I'm trying to run an unbalanced fixed effects model using plm. I'm not sure if this question has been answered as most of the answers on this web site are beyond my technological grasp. My data is set up in five…