Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
1 answer
160 views

Python function to merge columns into one column

I am trying to build a function, to apply to different columns with a csv file. The purpose of the function is to combine multiple columns into one, using the combine_first method described here: How ...
VBC's user avatar
  • 5
3 votes
2 answers
136 views

How do I append an input element with an attribute of checkbox?

I am new to JavaScript and attempting to create a to-do list. How can I append an input with a checkbox attribute to my code so that paragraphs can be checked off once completed? Here is my code below:...
Ruby's user avatar
  • 33
1 vote
1 answer
78 views

Julia: Function which uses append! modify its argument

I define a function which takes an array as argument, append some values to it and return the appended array. I see that the array I pass as an argument to the function is modified even though my ...
coussin's user avatar
  • 111
0 votes
3 answers
129 views

How to only get one vowel in a list?

I am having trouble getting the function to only print the vowel once if the string contains the vowel more than once. Here is the assignment: Write Python function vowelList that takes one string ...
RykerStrike's user avatar
0 votes
3 answers
103 views

Swift - function that does add one or more enum values to an array

Having a struct dat has a variable that may contain a array of one or more enum values. I want with one function the possibility to add one or more enum values, like: mutating func addEnumValue(value: ...
iPadawan's user avatar
  • 1,130
-1 votes
2 answers
64 views

How could i append to list any output that my function gives, including errors?

I want to apply my function func to a list of values and collect results. Sometimes it can output errors: JSONDecodeError, IndexError, etc. A list to which i collect results is result_list. And if ...
french_fries's user avatar
  • 1,199
0 votes
1 answer
49 views

Script is pasting data as #N/A rather than the value

I am using the following script to copy data from one sheet and paste to the last row of another. function menuItem1() { var ss = SpreadsheetApp.getActive(); var srcSheet = ss.getSheetByName("...
manc_stu's user avatar
1 vote
0 answers
113 views

Lua - Appending function properly

First I defined the AppendScript function local mt = { AppendScript = function(self, handler, method) local func = self:GetScript(handler) self:SetScript(handler, ...
user3713179's user avatar
0 votes
2 answers
36 views

Append dataframes in a for-loop within a function

Toy dataframe: df <- data.frame( country = factor(c('USA', 'USA', 'Japan')), dimension = factor(c('economic', 'cultural', 'religious'))) I attempt to write a function to collect level names ...
johnjohn's user avatar
  • 892
0 votes
1 answer
127 views

How can I call several user_names in the Twitter API?

I could successfully get the data of a user in Python by get_all_tweets(user_name). Now I would like to retrieve data from several users in the same code. I tried to copy the same code and append it ...
Picnic's user avatar
  • 23
-2 votes
1 answer
60 views

My for loop and the dot append function is not giving me what exactly I want

`I am working on a credit card validator that takes in up to 16 digits number which is, (the card number) and return the type of card it is. Before it gets to the part it returns the card type and ...
APY's user avatar
  • 11
1 vote
2 answers
47 views

Append a User Defined Function's output to a existing vector without printing the output in R

Suppose I have a blank vector - ot_vec = c() Now I have many user-defined functions e.g. Square_Calculator, SquareRoot_Calculator etc as defined below - square_calculator <- function(x){ sq = x*...
Debojit Roy's user avatar
0 votes
1 answer
385 views

Create a function which takes a list as an argument and keeps only the numbers that are greater than 5

I am trying to create a function that takes a list as an argument and keeps only the numbers that are greater than 5 by creating a new empty list inside the function and only append it with numbers ...
Ace's user avatar
  • 1
1 vote
1 answer
73 views

Vector of functions

I want to create a function that is modified with a loop and then I can call those different functions from a function vector. The function to be modified would be the Am function. The problem is that ...
Salvador Falcón Canillas's user avatar
0 votes
2 answers
46 views

Wrong output in function

Hi I'am totally new to programmering and i have just jumped into it. The problem i am trying to solve is to make a function that standardized an adress as input. example: def standardize_address(a): ...
Thomas R. Hansen's user avatar

15 30 50 per page
1
2 3 4 5
13