Questions tagged [predefined-variables]

59 questions
1
vote
1 answer

Is there a Predefined Identifier for how nested a function call is?

In order to debug a recursive program, I find it useful to visualize how deeply nested my function calls are. I'd love to have something like __func__, but for how deep my stack trace is instead of what my function name is. I understand that it…
Ari Sweedler
  • 807
  • 7
  • 25
1
vote
1 answer

Predefine the factors in table function in R

I would like to predefine the levels of the table function to make the results comparable among distinct datasets. Let's say that I would like to compare obj1 and obj2: obj1 <-c(1,1,1,2,3) obj2 <- c(1,1,1,2,2) If I use table function on them the…
user3091668
  • 2,230
  • 6
  • 25
  • 42
1
vote
1 answer

How to echo predefined variable from PowerShell command line?

I'm able to Write-Host a custom variable from PowerShell command line, but predefined variables are not working with same way. What is proper way to echo a predefined variable. Write-Host $path works. Write-Host $PSScriptRoot does not. Here is my…
1
vote
0 answers

Exclude the Predefined keywords from Word (alphanums+'_.') in pyparsing python

selectStmt=(select + ('*' |delimitedList(functionbody|column)).setResultsName("Columns") + Optional((_as+table.setResultsName("Aliases"))|table.setResultsName("**Aliases1**"),'')+ Optional(_into+('*'…
rajender kumar
  • 412
  • 3
  • 12
1
vote
2 answers

Python - Using a list of predefined variables in a loop (psychopy)

I am trying to write a piece of code that requires 200 text stimuli to be viewed for 1 second one after the other but I cant get my code to work. Each stimulus is predefined as a variable: redkey = visual.textStim(win, "key", (1.0, -1.0,…
Ron
  • 13
  • 2
1
vote
1 answer

Is there ways to be fold by using pre-defined strings?

I like to use vim to program c and c++, but I am disappointed to use the folding scheme, because I have a lot of definition in C. Such as CONFIG_A_DEFINEDED CONFIG_B_DEFINEDED CONFIG_C_DEFINEDED For example: #if config_a_defineded .. #endif #if…
kevinpark
  • 19
  • 2
1
vote
2 answers

How to echo filter used in filter_var

First I'll show the function: function validate($data, $filter){ if(!filter_var($data, $filter)) { return 'Filter used:'.$filter; } else { return 'good'; } } When I use this function it will look like this: $email =…
Redoneben
  • 126
  • 6
1
vote
1 answer

What is __VMKLNX__ in Linux header files?

In a lot of Linux kernel modules (hardware drivers) their source header files, one can spot lines like: #ifndef __VMKLNX__ __VMKLNX__ is not defined in the source code of this module. A guess is that __VMKLNX__ is a "C" system specific predefined…
1
vote
1 answer

Where has $> gone ?

This is one of solution to this problem. a=[];$<.map{|l|l=='0'?($>< which is $DEFAULT_OUTPUT gone? I used p $> etc but it does not output the result. How can I display the…
shin
  • 31,901
  • 69
  • 184
  • 271
0
votes
2 answers

Is there any way to predefine a string in vb6?

I was trying someting like: Dim experiment As String = "Predefined experiment string.." but sadly its not working so is there any way to predefine a string with a similar way in vb6?
Berker Yüceer
  • 7,026
  • 18
  • 68
  • 102
0
votes
1 answer

Is there a way to get the predefined constants as name, not its value?

I am writing a code to generate dynamic prepared queries in PDO. I have created an array that represents any table: $tableUser=array( "name"=>"user", "columns"=>array( array("name"=>"user_id", "type"=>PDO::PARAM_INT), …
A. Cedano
  • 557
  • 7
  • 39
0
votes
1 answer

How could I set C and gamma value for SVM in Matlab

I trt to train a pre-designed SVM with RBF kernel. I want to fix the C and gamma value before train. I use Mdl = fitcsvm(Xapp,Yapp,'KernelFunction','rbf','KernelScale', 1,'BoxConstraint', 1,...); But after training, the C(BoxConstraint) and…
0
votes
0 answers

Switch case statements in Shell scripting

I need some help with switch case statements in shell scripting. Here I am trying to read the Variable name and assign it to a switch case and based on the value of the switch case I want to assign a new name for the respective Variable name and…
0
votes
2 answers

Python - not exactly predefined 2D Array overwrites just all elements

Hey I want to create a 2d-Array with no predefined length and then replace the elements. without using numpy. Here a simplified version with my Problem: >>> test = 2*[2*[0]] >>> test[0][0] = "Hello" >>> print(test) [['Hello', 0], ['Hello', 0]] This…
0
votes
1 answer

Where are the predefined functions in Lua's files?

I'm looking to create my own scripting language, highly based off of lua (im planning on it being lua but easier to understand for me) so I need to know where the predetermined functions / variables file is, because I would like to edit that. If you…
Comm_GT
  • 3
  • 2